@tstdl/base 0.81.35 → 0.82.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.
Files changed (244) hide show
  1. package/api/client/client.d.ts +3 -3
  2. package/api/default-error-handlers.d.ts +1 -1
  3. package/api/response.d.ts +8 -8
  4. package/api/server/api-controller.d.ts +1 -1
  5. package/api/server/gateway.d.ts +9 -9
  6. package/api/server/middlewares/cors.middleware.d.ts +1 -1
  7. package/api/server/module.d.ts +1 -1
  8. package/api/types.d.ts +30 -30
  9. package/api/utils.d.ts +1 -1
  10. package/authentication/authentication-credentials.service.d.ts +6 -0
  11. package/authentication/authentication-credentials.service.js +17 -0
  12. package/authentication/authentication-credentials.service.js.map +1 -0
  13. package/authentication/authentication-session.service.d.ts +6 -0
  14. package/authentication/authentication-session.service.js +17 -0
  15. package/authentication/authentication-session.service.js.map +1 -0
  16. package/authentication/authentication-token-payload.provider.d.ts +3 -0
  17. package/authentication/authentication-token-payload.provider.js +17 -0
  18. package/authentication/authentication-token-payload.provider.js.map +1 -0
  19. package/authentication/authentication.service.d.ts +42 -0
  20. package/authentication/authentication.service.js +133 -0
  21. package/authentication/authentication.service.js.map +1 -0
  22. package/authentication/models/authentication-credentials.model.d.ts +6 -0
  23. package/authentication/models/authentication-credentials.model.js +37 -0
  24. package/authentication/models/authentication-credentials.model.js.map +1 -0
  25. package/authentication/models/authentication-session.model.d.ts +9 -0
  26. package/authentication/models/authentication-session.model.js +52 -0
  27. package/authentication/models/authentication-session.model.js.map +1 -0
  28. package/authentication/models/index.d.ts +2 -0
  29. package/authentication/models/index.js +19 -0
  30. package/authentication/models/index.js.map +1 -0
  31. package/authentication/tokens.d.ts +2 -0
  32. package/authentication/tokens.js +6 -0
  33. package/authentication/tokens.js.map +1 -0
  34. package/collections/keyed-set.d.ts +1 -1
  35. package/collections/observable/observable-collection.d.ts +1 -1
  36. package/collections/observable/observable-list.d.ts +2 -2
  37. package/container/container.d.ts +3 -3
  38. package/container/decorators.d.ts +3 -3
  39. package/container/interfaces.d.ts +1 -1
  40. package/container/provider.d.ts +6 -6
  41. package/container/resolve-chain.d.ts +2 -2
  42. package/container/token.d.ts +3 -3
  43. package/container/type-info.d.ts +1 -1
  44. package/container/types.d.ts +4 -4
  45. package/core.d.ts +1 -1
  46. package/data-structures/linked-list.d.ts +1 -1
  47. package/data-structures/multi-key-map.d.ts +2 -2
  48. package/data-structures/sorted-array-list.d.ts +1 -1
  49. package/database/entity-repository.d.ts +2 -2
  50. package/database/entity.d.ts +3 -3
  51. package/database/module.d.ts +1 -1
  52. package/database/mongo/classes.d.ts +3 -3
  53. package/database/mongo/model/document.d.ts +3 -3
  54. package/database/mongo/module.d.ts +1 -1
  55. package/database/mongo/mongo-base.repository.d.ts +11 -11
  56. package/database/mongo/mongo-bulk.d.ts +1 -1
  57. package/database/mongo/mongo-entity-repository.d.ts +7 -7
  58. package/database/mongo/types.d.ts +16 -16
  59. package/database/query.d.ts +38 -38
  60. package/disposable/async-disposer.d.ts +3 -3
  61. package/distributed-loop/distributed-loop.d.ts +2 -2
  62. package/error/custom.error.d.ts +1 -1
  63. package/http/client/adapters/undici-http-client.adapter.d.ts +1 -1
  64. package/http/client/http-client-request.d.ts +5 -5
  65. package/http/client/http-client-response.d.ts +2 -2
  66. package/http/client/http-client.d.ts +5 -5
  67. package/http/http-body.d.ts +3 -1
  68. package/http/http-body.js +18 -12
  69. package/http/http-body.js.map +1 -1
  70. package/http/http-form.d.ts +2 -2
  71. package/http/http-headers.d.ts +3 -3
  72. package/http/http-query.d.ts +2 -2
  73. package/http/http-url-parameters.d.ts +2 -2
  74. package/http/http-value-map.d.ts +1 -1
  75. package/http/server/http-server-request.d.ts +1 -1
  76. package/http/server/http-server-response.d.ts +1 -1
  77. package/http/server/http-server.d.ts +1 -1
  78. package/http/server/node/node-http-server.d.ts +1 -1
  79. package/http/types.d.ts +5 -5
  80. package/http/utils.d.ts +3 -3
  81. package/image-service/imgproxy/imgproxy-image-service.d.ts +1 -1
  82. package/json-path/json-path.d.ts +4 -4
  83. package/key-value-store/key-value.store.d.ts +1 -1
  84. package/key-value-store/mongo/module.d.ts +1 -1
  85. package/key-value-store/mongo/mongo-key-value.model.d.ts +1 -1
  86. package/lock/lock.d.ts +4 -4
  87. package/lock/mongo/model.d.ts +1 -1
  88. package/lock/mongo/module.d.ts +1 -1
  89. package/lock/provider.d.ts +1 -1
  90. package/logger/logger.d.ts +6 -6
  91. package/mail/mail.client.d.ts +1 -1
  92. package/mail/models/mail-address.model.d.ts +1 -1
  93. package/mail/models/mail-content.model.d.ts +1 -1
  94. package/mail/models/mail-data.model.d.ts +1 -1
  95. package/mail/models/mail-log.model.d.ts +2 -2
  96. package/mail/models/mail-send-result.model.d.ts +1 -1
  97. package/mail/models/mail-template.model.d.ts +1 -1
  98. package/mail/module.d.ts +1 -1
  99. package/mail/repositories/mongo-mail-log.repository.d.ts +2 -2
  100. package/message-bus/local/types.d.ts +1 -1
  101. package/message-bus/message-bus.d.ts +1 -1
  102. package/migration/migration-state.d.ts +2 -2
  103. package/migration/migrator.d.ts +4 -4
  104. package/migration/mongo/module.d.ts +1 -1
  105. package/module/module-metric-reporter.d.ts +2 -2
  106. package/module/module.d.ts +1 -1
  107. package/module/modules/function.module.d.ts +1 -1
  108. package/module/modules/web-server.module.d.ts +1 -1
  109. package/notification/api.d.ts +1 -1
  110. package/notification/module.d.ts +1 -1
  111. package/object-storage/object-storage.d.ts +2 -2
  112. package/object-storage/object.d.ts +1 -1
  113. package/object-storage/s3/s3.object-storage-provider.d.ts +1 -1
  114. package/openid-connect/mongo-oidc-state.repository.d.ts +1 -1
  115. package/openid-connect/oidc-configuration.service.d.ts +1 -1
  116. package/openid-connect/oidc-state.model.d.ts +2 -2
  117. package/openid-connect/oidc.service-model.d.ts +8 -8
  118. package/orm/types.d.ts +4 -4
  119. package/package.json +3 -3
  120. package/pdf/pdf.service.d.ts +3 -3
  121. package/pool/pool.d.ts +4 -4
  122. package/promise/cancelable-promise.d.ts +1 -1
  123. package/promise/lazy-promise.d.ts +1 -1
  124. package/queue/mongo/job.d.ts +2 -2
  125. package/queue/mongo/queue.js +2 -2
  126. package/queue/mongo/queue.js.map +1 -1
  127. package/queue/queue.d.ts +11 -6
  128. package/queue/queue.js +2 -1
  129. package/queue/queue.js.map +1 -1
  130. package/reflection/registry.d.ts +9 -9
  131. package/reflection/types.d.ts +32 -32
  132. package/reflection/utils.d.ts +5 -5
  133. package/rpc/endpoints/message-port.rpc-endpoint.d.ts +3 -3
  134. package/rpc/model.d.ts +22 -22
  135. package/rpc/rpc.d.ts +1 -1
  136. package/rxjs/intersection-observer.d.ts +1 -1
  137. package/rxjs/mutation-observer.d.ts +1 -1
  138. package/rxjs/performance-observer.d.ts +1 -1
  139. package/rxjs/resize-observer.d.ts +1 -1
  140. package/rxjs/slow-array.d.ts +1 -1
  141. package/rxjs/touch.d.ts +1 -1
  142. package/schema/constraints/generic.d.ts +2 -2
  143. package/schema/constraints/length.d.ts +1 -1
  144. package/schema/decorators/types.d.ts +3 -3
  145. package/schema/schema.d.ts +4 -4
  146. package/schema/schema.error.d.ts +1 -1
  147. package/schema/schema.js +10 -13
  148. package/schema/schema.js.map +1 -1
  149. package/schema/schemas/any.d.ts +1 -1
  150. package/schema/schemas/array.d.ts +1 -1
  151. package/schema/schemas/boolean.d.ts +1 -1
  152. package/schema/schemas/date.d.ts +1 -1
  153. package/schema/schemas/enumeration.d.ts +1 -1
  154. package/schema/schemas/instance.d.ts +1 -1
  155. package/schema/schemas/literal.d.ts +1 -1
  156. package/schema/schemas/nullable.d.ts +1 -1
  157. package/schema/schemas/number.d.ts +1 -1
  158. package/schema/schemas/object.d.ts +1 -1
  159. package/schema/schemas/one-or-many.d.ts +2 -2
  160. package/schema/schemas/optional.d.ts +1 -1
  161. package/schema/schemas/readable-stream.d.ts +1 -1
  162. package/schema/schemas/record.d.ts +1 -1
  163. package/schema/schemas/regexp.d.ts +1 -1
  164. package/schema/schemas/string.d.ts +1 -1
  165. package/schema/schemas/uint8-array.d.ts +1 -1
  166. package/schema/schemas/union.d.ts +1 -1
  167. package/schema/schemas/unknown.d.ts +1 -1
  168. package/schema/transformers/generic.d.ts +1 -1
  169. package/schema/types.d.ts +31 -31
  170. package/search-index/elastic/config.d.ts +1 -1
  171. package/search-index/elastic/model/elastic-query.d.ts +15 -15
  172. package/search-index/elastic/model/index-mapping.d.ts +14 -14
  173. package/search-index/elastic/model/sort.d.ts +3 -3
  174. package/search-index/elastic/module.d.ts +1 -1
  175. package/search-index/search-index.d.ts +1 -1
  176. package/search-index/search-result.d.ts +2 -2
  177. package/serializer/handlers/error.d.ts +1 -1
  178. package/serializer/handlers/map.d.ts +1 -1
  179. package/serializer/handlers/regex.d.ts +1 -1
  180. package/serializer/handlers/set.d.ts +1 -1
  181. package/serializer/serializable.d.ts +6 -6
  182. package/serializer/serializer.d.ts +1 -1
  183. package/serializer/types.d.ts +15 -15
  184. package/sse/server-sent-events.d.ts +3 -3
  185. package/tailwind/theme-adapter.d.ts +1 -1
  186. package/templates/module.d.ts +1 -1
  187. package/templates/providers/file.provider-template.d.ts +2 -2
  188. package/templates/providers/file.provider-template.js +2 -1
  189. package/templates/providers/file.provider-template.js.map +1 -1
  190. package/templates/renderers/handlebars.template-renderer.d.ts +9 -9
  191. package/templates/renderers/mjml.template-renderer.d.ts +3 -3
  192. package/templates/renderers/string.template-renderer.d.ts +1 -1
  193. package/templates/resolvers/file.template-resolver.d.ts +2 -2
  194. package/templates/template.model.d.ts +1 -1
  195. package/templates/template.renderer.d.ts +4 -4
  196. package/templates/template.service.d.ts +1 -1
  197. package/text/dynamic-text.model.d.ts +1 -1
  198. package/text/localizable-text.model.d.ts +1 -1
  199. package/text/localization.service.d.ts +11 -11
  200. package/theme/theme-service.d.ts +6 -6
  201. package/threading/thread-pool.d.ts +1 -1
  202. package/threading/thread-worker.d.ts +1 -1
  203. package/types/geo-json.d.ts +12 -12
  204. package/types.d.ts +91 -91
  205. package/utils/any-iterable-iterator.d.ts +3 -3
  206. package/utils/async-iterable-helpers/parallel/types.d.ts +2 -2
  207. package/utils/async-iterable-helpers/types.d.ts +7 -7
  208. package/utils/backoff.d.ts +5 -5
  209. package/utils/benchmark.d.ts +1 -1
  210. package/utils/binary-search.d.ts +1 -1
  211. package/utils/binary.js.map +1 -1
  212. package/utils/cancellation-token.d.ts +1 -1
  213. package/utils/compression.d.ts +1 -1
  214. package/utils/cryptography.d.ts +11 -11
  215. package/utils/date-time.d.ts +8 -7
  216. package/utils/date-time.js +6 -2
  217. package/utils/date-time.js.map +1 -1
  218. package/utils/equals.d.ts +3 -3
  219. package/utils/factory-map.d.ts +1 -1
  220. package/utils/format-error.d.ts +1 -1
  221. package/utils/function/memoize.d.ts +1 -1
  222. package/utils/helpers.d.ts +1 -1
  223. package/utils/iterable-helpers/types.d.ts +6 -6
  224. package/utils/jwt.d.ts +4 -4
  225. package/utils/math.d.ts +1 -1
  226. package/utils/merge.d.ts +1 -1
  227. package/utils/middleware.d.ts +9 -9
  228. package/utils/moving-metric.d.ts +1 -1
  229. package/utils/object/decycle.d.ts +1 -1
  230. package/utils/object/dereference.d.ts +1 -1
  231. package/utils/object/forward-ref.d.ts +2 -2
  232. package/utils/object/lazy-property.d.ts +5 -5
  233. package/utils/object/merge.d.ts +1 -1
  234. package/utils/object/property-name.d.ts +5 -5
  235. package/utils/patch-worker.d.ts +1 -1
  236. package/utils/periodic-sampler.d.ts +1 -1
  237. package/utils/provider-function-iterable.d.ts +2 -2
  238. package/utils/proxy.d.ts +1 -1
  239. package/utils/singleton.d.ts +2 -2
  240. package/utils/sort.d.ts +2 -2
  241. package/utils/stream/stream-helper-types.d.ts +5 -5
  242. package/utils/type-guards.d.ts +3 -3
  243. package/utils/url-builder.d.ts +4 -4
  244. package/web-types.d.ts +4 -4
@@ -1,7 +1,7 @@
1
1
  import type { ReadonlyCancellationToken } from './cancellation-token';
2
2
  import { CancellationToken } from './cancellation-token';
3
- export declare type BackoffStrategy = 'linear' | 'exponential';
4
- export declare type BackoffOptions = {
3
+ export type BackoffStrategy = 'linear' | 'exponential';
4
+ export type BackoffOptions = {
5
5
  /**
6
6
  * how to increase delay
7
7
  */
@@ -19,7 +19,7 @@ export declare type BackoffOptions = {
19
19
  */
20
20
  maximumDelay?: number;
21
21
  };
22
- export declare type BackoffLoopController = {
22
+ export type BackoffLoopController = {
23
23
  /**
24
24
  * backoff before next iteration
25
25
  */
@@ -29,11 +29,11 @@ export declare type BackoffLoopController = {
29
29
  */
30
30
  break: () => void;
31
31
  };
32
- export declare type BackoffLoopFunction = (controller: BackoffLoopController) => void | Promise<void>;
32
+ export type BackoffLoopFunction = (controller: BackoffLoopController) => void | Promise<void>;
33
33
  /**
34
34
  * @param continueToken token to continue loop immediately
35
35
  */
36
- export declare type BackoffGeneratorYield = (continueToken?: CancellationToken) => void;
36
+ export type BackoffGeneratorYield = (continueToken?: CancellationToken) => void;
37
37
  export declare class BackoffHelper {
38
38
  private readonly strategy;
39
39
  private readonly initialDelay;
@@ -1,4 +1,4 @@
1
- export declare type BenchmarkResult = {
1
+ export type BenchmarkResult = {
2
2
  operationsPerMillisecond: number;
3
3
  millisecondsPerOperation: number;
4
4
  };
@@ -1,5 +1,5 @@
1
1
  import type { Comparator } from './sort';
2
- export declare type BinarySearchOptions = {
2
+ export type BinarySearchOptions = {
3
3
  /** minimum index to search at */
4
4
  min?: number;
5
5
  /** maximum index to search at */
@@ -1 +1 @@
1
- {"version":3,"file":"binary.js","sourceRoot":"","sources":["../../source/utils/binary.ts"],"names":[],"mappings":";;;AAAA,0CAA4C;AAE5C,+CAAsD;AAEtD;;;;GAIG;AACH,SAAgB,aAAa,CAAC,IAAgB,EAAE,QAAiB,KAAK;IACpE,IAAI,IAAA,2BAAa,EAAC,IAAI,CAAC,EAAE;QACvB,OAAO,KAAK,CAAC,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC;KACrC;IAED,IAAI,CAAC,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C,MAAM,CAAC,MAAM,GAAG,CAAC,EAAE,oBAAoB,CAAC,CAAC;IAEhD,MAAM,IAAI,GAAG,MAAM,CAAC,CAAC,CAAE,CAAC,WAAW,CAAC;IAEpC,IAAI,yBAAc,IAAI,CAAC,CAAC,IAAI,IAAI,MAAM,CAAC,IAAI,CAAC,IAAI,IAAI,UAAU,CAAC,CAAC,EAAE;QAChE,OAAO,MAAM,CAAC,MAAM,CAAC,MAA6B,EAAE,WAAW,CAAiB,CAAC;KAClF;IAED,MAAM,UAAU,GAAG,WAAW,IAAI,MAAM,CAAC,MAAM,CAAC,CAAC,GAAG,EAAE,KAAK,EAAE,EAAE,CAAC,GAAG,GAAG,KAAK,CAAC,UAAU,EAAE,CAAC,CAAC,CAAC;IAC3F,MAAM,MAAM,GAAG,IAAI,UAAU,CAAC,UAAU,CAAC,CAAC;IAE1C,IAAI,YAAY,GAAG,CAAC,CAAC;IACrB,KAAK,MAAM,KAAK,IAAI,MAAM,EAAE;QAC1B,MAAM,UAAU,GAAG,YAAY,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC;QAC9C,MAAM,CAAC,GAAG,CAAC,UAAU,EAAE,YAAY,CAAC,CAAC;QACrC,YAAY,IAAI,UAAU,CAAC,UAAU,CAAC;KACvC;IAED,OAAO,IAAK,IAA8B,CAAC,MAAM,CAAC,MAAM,CAAiB,CAAC;AAC5E,CAAC;AApBD,wDAoBC"}
@@ -1,5 +1,5 @@
1
1
  import type { Observable, Observer, Subscribable, Subscription } from 'rxjs';
2
- export declare type ConnectConfig = {
2
+ export type ConnectConfig = {
3
3
  /**
4
4
  * Propagate parent set to child.
5
5
  * @default true
@@ -13,7 +13,7 @@ export interface CompressionResult {
13
13
  export interface DecompressionResult extends CompressionResult {
14
14
  toUtf8(): Promise<string>;
15
15
  }
16
- export declare type CompressionAlgorithm = 'gzip' | 'brotli' | 'deflate' | 'deflate-raw';
16
+ export type CompressionAlgorithm = 'gzip' | 'brotli' | 'deflate' | 'deflate-raw';
17
17
  export declare function compressString(input: string, algorithm: 'gzip' | 'deflate' | 'deflate-raw', options?: ZlibType.ZlibOptions): CompressionResult;
18
18
  export declare function compressString(input: string, algorithm: 'brotli', options?: ZlibType.BrotliOptions): CompressionResult;
19
19
  export declare function compressString(input: string, algorithm: CompressionAlgorithm, options?: ZlibType.ZlibOptions | ZlibType.BrotliOptions): CompressionResult;
@@ -1,15 +1,15 @@
1
1
  import type { BinaryData, TypedExtract } from "../types";
2
- export declare type AesMode = 'CBC' | 'CTR' | 'GCM' | 'KW';
3
- export declare type EcdsaCurve = 'P-256' | 'P-384' | 'P-521';
4
- export declare type HashAlgorithm = 'SHA-1' | 'SHA-256' | 'SHA-384' | 'SHA-512';
5
- export declare type SymmetricAlgorithm = `AES-${AesMode}`;
6
- export declare type AsymmetricAlgorithm = 'RSASSA-PKCS1-v1_5' | 'RSA-PSS' | 'RSA-OAEP' | 'ECDSA' | 'ECDH' | 'NODE-DSA' | 'NODE-DH' | 'NODE-ED25519' | 'NODE-ED448';
7
- export declare type CryptionAlgorithm = Parameters<typeof crypto.subtle.encrypt>[0];
8
- export declare type SignAlgorithm = Parameters<typeof crypto.subtle.sign>[0];
9
- export declare type KeyAlgorithm = Parameters<typeof crypto.subtle.generateKey>[0];
10
- export declare type KeyType = 'raw' | 'pkcs8' | 'spki' | 'jwk';
11
- export declare type Key = JsonWebKey | BinaryData;
12
- export declare type ScryptOptions = {
2
+ export type AesMode = 'CBC' | 'CTR' | 'GCM' | 'KW';
3
+ export type EcdsaCurve = 'P-256' | 'P-384' | 'P-521';
4
+ export type HashAlgorithm = 'SHA-1' | 'SHA-256' | 'SHA-384' | 'SHA-512';
5
+ export type SymmetricAlgorithm = `AES-${AesMode}`;
6
+ export type AsymmetricAlgorithm = 'RSASSA-PKCS1-v1_5' | 'RSA-PSS' | 'RSA-OAEP' | 'ECDSA' | 'ECDH' | 'NODE-DSA' | 'NODE-DH' | 'NODE-ED25519' | 'NODE-ED448';
7
+ export type CryptionAlgorithm = Parameters<typeof crypto.subtle.encrypt>[0];
8
+ export type SignAlgorithm = Parameters<typeof crypto.subtle.sign>[0];
9
+ export type KeyAlgorithm = Parameters<typeof crypto.subtle.generateKey>[0];
10
+ export type KeyType = 'raw' | 'pkcs8' | 'spki' | 'jwk';
11
+ export type Key = JsonWebKey | BinaryData;
12
+ export type ScryptOptions = {
13
13
  cost?: number;
14
14
  blockSize?: number;
15
15
  parallelization?: number;
@@ -1,33 +1,34 @@
1
1
  import type { DateObjectUnits, DateTimeJSOptions } from 'luxon';
2
2
  import { DateTime } from 'luxon';
3
- export declare type DateObject = {
3
+ export type DateObject = {
4
4
  year: number;
5
5
  month: number;
6
6
  day: number;
7
7
  };
8
- export declare type ZonedDateObject = DateObject & {
8
+ export type ZonedDateObject = DateObject & {
9
9
  zone: string;
10
10
  };
11
- export declare type TimeObject = {
11
+ export type TimeObject = {
12
12
  hour: number;
13
13
  minute: number;
14
14
  second: number;
15
15
  millisecond: number;
16
16
  };
17
- export declare type ZonedTimeObject = TimeObject & {
17
+ export type ZonedTimeObject = TimeObject & {
18
18
  zone: string;
19
19
  };
20
- export declare type SimpleDateTimeObject = DateObject & TimeObject;
21
- export declare type ZonedDateTimeObject = SimpleDateTimeObject & {
20
+ export type SimpleDateTimeObject = DateObject & TimeObject;
21
+ export type ZonedDateTimeObject = SimpleDateTimeObject & {
22
22
  zone: string;
23
23
  };
24
- export declare type NumericDateTime = {
24
+ export type NumericDateTime = {
25
25
  date: number;
26
26
  time: number;
27
27
  };
28
28
  export declare function now(): Date;
29
29
  export declare function currentTimestamp(): number;
30
30
  export declare function currentTimestampSeconds(): number;
31
+ export declare function timestampToTimestampSeconds(timestamp: number): number;
31
32
  export declare function currentDate(): number;
32
33
  export declare function currentTime(): number;
33
34
  export declare function timestampToNumericDate(timestamp: number): number;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.numericDateTimeToDateTime = exports.dateTimeToTime = exports.numericDateToDateTime = exports.dateTimeToNumericDate = exports.zonedDateObjectToDateTime = exports.numericDateTimeToTimestamp = exports.numericDateToDate = exports.numericDateToTimestamp = exports.timestampToNumericDateAndTime = exports.numericTimeToTimeObject = exports.timeObjectToNumericTime = exports.timestampToTime = exports.dateToNumericDate = exports.timestampToNumericDate = exports.currentTime = exports.currentDate = exports.currentTimestampSeconds = exports.currentTimestamp = exports.now = void 0;
3
+ exports.numericDateTimeToDateTime = exports.dateTimeToTime = exports.numericDateToDateTime = exports.dateTimeToNumericDate = exports.zonedDateObjectToDateTime = exports.numericDateTimeToTimestamp = exports.numericDateToDate = exports.numericDateToTimestamp = exports.timestampToNumericDateAndTime = exports.numericTimeToTimeObject = exports.timeObjectToNumericTime = exports.timestampToTime = exports.dateToNumericDate = exports.timestampToNumericDate = exports.currentTime = exports.currentDate = exports.timestampToTimestampSeconds = exports.currentTimestampSeconds = exports.currentTimestamp = exports.now = void 0;
4
4
  const luxon_1 = require("luxon");
5
5
  const units_1 = require("./units");
6
6
  function now() {
@@ -12,9 +12,13 @@ function currentTimestamp() {
12
12
  }
13
13
  exports.currentTimestamp = currentTimestamp;
14
14
  function currentTimestampSeconds() {
15
- return Math.floor(Date.now() / 1000);
15
+ return timestampToTimestampSeconds(currentTimestamp());
16
16
  }
17
17
  exports.currentTimestampSeconds = currentTimestampSeconds;
18
+ function timestampToTimestampSeconds(timestamp) {
19
+ return Math.floor(timestamp / 1000);
20
+ }
21
+ exports.timestampToTimestampSeconds = timestampToTimestampSeconds;
18
22
  function currentDate() {
19
23
  const timestamp = currentTimestamp();
20
24
  return timestampToNumericDate(timestamp);
@@ -1 +1 @@
1
- {"version":3,"file":"date-time.js","sourceRoot":"","sources":["../../source/utils/date-time.ts"],"names":[],"mappings":";;;AACA,iCAAiC;AACjC,mCAAgH;AAkChH,SAAgB,GAAG;IACjB,OAAO,IAAI,IAAI,EAAE,CAAC;AACpB,CAAC;AAFD,kBAEC;AAED,SAAgB,gBAAgB;IAC9B,OAAO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: {
8
8
  readonly symbol: typeof equalsSymbol;
9
9
  };
10
- export declare type ArrayEqualsComparator<A, B> = (a: A, b: B) => boolean;
11
- export declare type ArrayEqualsOptions<A, B> = {
10
+ export type ArrayEqualsComparator<A, B> = (a: A, b: B) => boolean;
11
+ export type ArrayEqualsOptions<A, B> = {
12
12
  sort?: Comparator<A | B>;
13
13
  comparator?: ArrayEqualsComparator<A, B>;
14
14
  };
15
15
  export declare function arrayEquals<A, B>(a: readonly A[], b: readonly B[], options?: ArrayEqualsOptions<A, B>): boolean;
16
- export declare type EqualsOptions = {
16
+ export type EqualsOptions = {
17
17
  deep?: boolean;
18
18
  arrayDeep?: boolean;
19
19
  sortArray?: boolean;
@@ -1,4 +1,4 @@
1
- export declare type Factory<Key, Value> = (key: Key) => Value;
1
+ export type Factory<Key, Value> = (key: Key) => Value;
2
2
  /** same as {@link Map}, except that it will build the value with the provided factory on {@link get} if it doesnt exist */
3
3
  export declare class FactoryMap<K, V> implements Map<K, V> {
4
4
  private readonly factory;
@@ -1,5 +1,5 @@
1
1
  import type { UndefinableJson } from "../types";
2
- export declare type FormatErrorOptions = {
2
+ export type FormatErrorOptions = {
3
3
  /**
4
4
  * include all error properties beside name and message
5
5
  */
@@ -1,4 +1,4 @@
1
- export declare type MemoizeOptions = {
1
+ export type MemoizeOptions = {
2
2
  /** Use WeakMap instead of Map for caching. Can be used with object parameters only */
3
3
  weak?: boolean;
4
4
  };
@@ -26,7 +26,7 @@ export declare function parseFirstAndFamilyName(name: string): {
26
26
  firstName: string | undefined;
27
27
  familyName: string | undefined;
28
28
  };
29
- export declare type NormalizeTextOptions = {
29
+ export type NormalizeTextOptions = {
30
30
  /**
31
31
  * remove leading and trailing whitespace
32
32
  */
@@ -1,12 +1,12 @@
1
- export declare type Context<T> = {
1
+ export type Context<T> = {
2
2
  item: T;
3
3
  readonly index: number;
4
4
  };
5
- export declare type TypePredicate<T, TPredicate extends T> = (item: T, index: number) => item is TPredicate;
6
- export declare type Predicate<T> = (item: T, index: number) => boolean;
7
- export declare type IteratorFunction<TIn, TOut> = (item: TIn, index: number) => TOut;
8
- export declare type Reducer<T, U> = (previous: U, current: T, index: number) => U;
9
- export declare type IterableItemMetadata<T> = {
5
+ export type TypePredicate<T, TPredicate extends T> = (item: T, index: number) => item is TPredicate;
6
+ export type Predicate<T> = (item: T, index: number) => boolean;
7
+ export type IteratorFunction<TIn, TOut> = (item: TIn, index: number) => TOut;
8
+ export type Reducer<T, U> = (previous: U, current: T, index: number) => U;
9
+ export type IterableItemMetadata<T> = {
10
10
  index: number;
11
11
  isFirst: boolean;
12
12
  isLast: boolean;
package/utils/jwt.d.ts CHANGED
@@ -1,15 +1,15 @@
1
1
  import type { OneOrMany, StringMap } from '../types';
2
2
  import type { Key } from './cryptography';
3
- export declare type JwtTokenAlgorithm = 'HS256' | 'HS384' | 'HS512';
4
- export declare type JwtTokenHeader<T extends StringMap = StringMap> = {
3
+ export type JwtTokenAlgorithm = 'HS256' | 'HS384' | 'HS512';
4
+ export type JwtTokenHeader<T extends StringMap = StringMap> = {
5
5
  alg: JwtTokenAlgorithm;
6
6
  typ: 'JWT';
7
7
  } & T;
8
- export declare type JwtToken<TPayload = StringMap, THeader extends JwtTokenHeader = JwtTokenHeader> = {
8
+ export type JwtToken<TPayload = StringMap, THeader extends JwtTokenHeader = JwtTokenHeader> = {
9
9
  readonly header: THeader;
10
10
  readonly payload: TPayload;
11
11
  };
12
- export declare type JwtTokenParseResult<T extends JwtToken = JwtToken> = {
12
+ export type JwtTokenParseResult<T extends JwtToken = JwtToken> = {
13
13
  raw: string;
14
14
  token: T;
15
15
  encoded: {
package/utils/math.d.ts CHANGED
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * Generates a random value in interval [0, 1).
3
3
  */
4
- export declare type RandomNumberGenerator = () => number;
4
+ export type RandomNumberGenerator = () => number;
5
5
  /**
6
6
  * Generate a random float in interval [min, max).
7
7
  * @param min minimum value
package/utils/merge.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import type { Record } from "../types";
2
2
  import type { Merge } from 'type-fest';
3
- declare type BaseType = Record | any[] | Map<any, any> | Set<any>;
3
+ type BaseType = Record | any[] | Map<any, any> | Set<any>;
4
4
  export declare function merge<A extends BaseType, B extends BaseType>(a: A | undefined, b: B | undefined): A extends (infer T)[] ? B extends (infer U)[] ? (T | U)[] : never : A extends Map<infer K, infer V> ? B extends Map<infer K2, infer V2> ? Map<K | K2, V | V2> : never : A extends Set<infer T> ? B extends Set<infer U> ? Set<T | U> : never : A extends Record ? B extends Record ? Merge<A, B> : never : never;
5
5
  export {};
@@ -1,12 +1,12 @@
1
- export declare type ComposedMiddleware<TIn, TOut, Context = unknown> = (value: TIn, context: Context) => TOut;
2
- export declare type MiddlewareHandler<TIn, TOut, Context = unknown> = (value: TIn, context: Context) => TOut;
3
- export declare type MiddlewareNext<TIn, TOut> = (value: TIn) => TOut;
4
- export declare type Middleware<TIn, TOut, Context = unknown> = (value: TIn, next: MiddlewareNext<TIn, TOut>, context: Context) => TOut | TOut;
5
- export declare type ComposedAsyncMiddleware<TIn, TOut, Context = unknown> = (value: TIn, context: Context) => Promise<TOut>;
6
- export declare type AsyncMiddlewareHandler<TIn, TOut, Context = unknown> = (value: TIn, context: Context) => TOut | Promise<TOut>;
7
- export declare type AsyncMiddlewareNext<TIn, TOut> = (value: TIn) => TOut | Promise<TOut>;
8
- export declare type AsyncMiddleware<TIn, TOut, Context = unknown> = (value: TIn, next: AsyncMiddlewareNext<TIn, TOut>, context: Context) => TOut | Promise<TOut>;
9
- export declare type MiddlewareOptions = {
1
+ export type ComposedMiddleware<TIn, TOut, Context = unknown> = (value: TIn, context: Context) => TOut;
2
+ export type MiddlewareHandler<TIn, TOut, Context = unknown> = (value: TIn, context: Context) => TOut;
3
+ export type MiddlewareNext<TIn, TOut> = (value: TIn) => TOut;
4
+ export type Middleware<TIn, TOut, Context = unknown> = (value: TIn, next: MiddlewareNext<TIn, TOut>, context: Context) => TOut | TOut;
5
+ export type ComposedAsyncMiddleware<TIn, TOut, Context = unknown> = (value: TIn, context: Context) => Promise<TOut>;
6
+ export type AsyncMiddlewareHandler<TIn, TOut, Context = unknown> = (value: TIn, context: Context) => TOut | Promise<TOut>;
7
+ export type AsyncMiddlewareNext<TIn, TOut> = (value: TIn) => TOut | Promise<TOut>;
8
+ export type AsyncMiddleware<TIn, TOut, Context = unknown> = (value: TIn, next: AsyncMiddlewareNext<TIn, TOut>, context: Context) => TOut | Promise<TOut>;
9
+ export type MiddlewareOptions = {
10
10
  allowMultipleNextCalls?: boolean;
11
11
  };
12
12
  export declare function composeMiddleware<TIn, TOut, Context = unknown>(middlewares: Middleware<TIn, TOut, Context>[], handler: MiddlewareHandler<TIn, TOut, Context>, options?: MiddlewareOptions): ComposedMiddleware<TIn, TOut, Context>;
@@ -9,7 +9,7 @@ export declare enum MetricAggregation {
9
9
  Rate = 7,
10
10
  RateBySum = 8
11
11
  }
12
- export declare type MetricAggregationOptions<T extends MetricAggregation> = T extends MetricAggregation.Quantile ? {
12
+ export type MetricAggregationOptions<T extends MetricAggregation> = T extends MetricAggregation.Quantile ? {
13
13
  scalar: number;
14
14
  } : never;
15
15
  export declare class MovingMetric {
@@ -1,5 +1,5 @@
1
1
  import type { Record } from "../../types";
2
- export declare type Decycled<T> = {
2
+ export type Decycled<T> = {
3
3
  __type: T;
4
4
  } & Record<string>;
5
5
  /**
@@ -1,5 +1,5 @@
1
1
  import type { JsonPathInput } from "../../json-path";
2
- export declare type CompiledDereferencer = (object: object) => unknown;
2
+ export type CompiledDereferencer = (object: object) => unknown;
3
3
  /**
4
4
  * compiles a dereferencer for a specific reference
5
5
  * @param object object to dereference
@@ -1,9 +1,9 @@
1
1
  declare const isForwardRef: unique symbol;
2
- export declare type ForwardRefOptions<T extends object = object> = {
2
+ export type ForwardRefOptions<T extends object = object> = {
3
3
  reference?: T;
4
4
  initializer?: () => T;
5
5
  };
6
- export declare type ForwardRef<T extends object = object> = T & {
6
+ export type ForwardRef<T extends object = object> = T & {
7
7
  [isForwardRef]: true;
8
8
  };
9
9
  export declare const ForwardRef: {
@@ -1,7 +1,7 @@
1
1
  import type { IfUnknown } from "../../types";
2
2
  declare const lazyObjectValueSymbol: unique symbol;
3
- export declare type LazyPropertyInitializer<T, K extends keyof T> = (this: T, key: K) => T[K];
4
- export declare type LazyPropertyObjectDefinition<T extends object, P extends keyof T> = LazyPropertyDescriptor & {
3
+ export type LazyPropertyInitializer<T, K extends keyof T> = (this: T, key: K) => T[K];
4
+ export type LazyPropertyObjectDefinition<T extends object, P extends keyof T> = LazyPropertyDescriptor & {
5
5
  /** define property with existing value */
6
6
  value?: T[P];
7
7
  /** define property with getter */
@@ -11,12 +11,12 @@ export declare type LazyPropertyObjectDefinition<T extends object, P extends key
11
11
  /** lazily define property with initializer */
12
12
  initializer?: LazyPropertyInitializer<T, P>;
13
13
  };
14
- export declare type LazyObjectValue<T> = {
14
+ export type LazyObjectValue<T> = {
15
15
  [lazyObjectValueSymbol]: typeof lazyObjectValueSymbol;
16
16
  value: T;
17
17
  };
18
- export declare type LazyInitializerItem<T extends object, P extends keyof T> = Exclude<IfUnknown<T[P], never, T[P]>, Function | object> | LazyPropertyInitializer<T, P> | LazyPropertyObjectDefinition<T, P> | LazyObjectValue<T[P]>;
19
- export declare type LazyPropertyDescriptor = {
18
+ export type LazyInitializerItem<T extends object, P extends keyof T> = Exclude<IfUnknown<T[P], never, T[P]>, Function | object> | LazyPropertyInitializer<T, P> | LazyPropertyObjectDefinition<T, P> | LazyObjectValue<T[P]>;
19
+ export type LazyPropertyDescriptor = {
20
20
  /**
21
21
  * true if the type of this property descriptor may be changed and if the property may be deleted from the corresponding object
22
22
  * @default true
@@ -1,4 +1,4 @@
1
- export declare type MergeObjectsOptions = {
1
+ export type MergeObjectsOptions = {
2
2
  /**
3
3
  * whether to merge arrays or ensure they are equal
4
4
  * @default 'merge'
@@ -1,21 +1,21 @@
1
1
  import type { DeepFlatten, DeepNonNullable, Record } from "../../types";
2
2
  export declare const propertyName: unique symbol;
3
3
  export declare const cast: unique symbol;
4
- export declare type PropertyName = {
4
+ export type PropertyName = {
5
5
  [propertyName]: string;
6
6
  };
7
- export declare type PropertyNameProxy<T extends Record> = {
7
+ export type PropertyNameProxy<T extends Record> = {
8
8
  [P in keyof DeepNonNullable<T>]: PropertyNameProxyChild<T[P]>;
9
9
  };
10
- export declare type PropertyNameProxyChild<T> = (T extends Record ? (PropertyNameProxy<T> & PropertyName) : (PropertyName)) & {
10
+ export type PropertyNameProxyChild<T> = (T extends Record ? (PropertyNameProxy<T> & PropertyName) : (PropertyName)) & {
11
11
  [cast]: <U extends T>() => PropertyNameProxyChild<U>;
12
12
  };
13
- export declare type PropertyNameOfExpressionObject<T> = {
13
+ export type PropertyNameOfExpressionObject<T> = {
14
14
  [P in keyof DeepNonNullable<T>]: PropertyNameOfExpressionObject<DeepNonNullable<T>[P]> & {
15
15
  [cast]: <U extends DeepNonNullable<T>[P]>() => PropertyNameOfExpressionObject<U>;
16
16
  };
17
17
  };
18
- export declare type FlatPropertyNameOfExpressionObject<T> = {
18
+ export type FlatPropertyNameOfExpressionObject<T> = {
19
19
  [P in keyof DeepFlatten<DeepNonNullable<T>>]: FlatPropertyNameOfExpressionObject<DeepFlatten<DeepNonNullable<T>>[P]> & {
20
20
  [cast]: <U extends DeepFlatten<DeepNonNullable<T>>[P]>() => FlatPropertyNameOfExpressionObject<U>;
21
21
  };
@@ -1,6 +1,6 @@
1
1
  import type { Record, StringMap } from "../types";
2
2
  import type { Observable } from 'rxjs';
3
- export declare type PatchWorkerOptions<T extends StringMap> = {
3
+ export type PatchWorkerOptions<T extends StringMap> = {
4
4
  debounceTime?: number;
5
5
  retryDelay?: number;
6
6
  handleOn?: Observable<any>;
@@ -7,7 +7,7 @@ export declare enum AggregationMode {
7
7
  FirstQuartile = 4,
8
8
  ThirdQuartile = 5
9
9
  }
10
- export declare type SampleFunction = () => number | Promise<number>;
10
+ export type SampleFunction = () => number | Promise<number>;
11
11
  export declare class PeriodicSampler {
12
12
  private readonly sampleFunction;
13
13
  private readonly subject;
@@ -1,5 +1,5 @@
1
- export declare type ProviderFunction<T> = () => ProviderFunctionResult<T> | Promise<ProviderFunctionResult<T>>;
2
- export declare type ProviderFunctionResult<T> = {
1
+ export type ProviderFunction<T> = () => ProviderFunctionResult<T> | Promise<ProviderFunctionResult<T>>;
2
+ export type ProviderFunctionResult<T> = {
3
3
  hasItem: boolean;
4
4
  item: T;
5
5
  } | {
package/utils/proxy.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  export declare const reflectMethodsMap: Record<keyof ProxyHandler<object>, true>;
2
- export declare type ReflectMethodsReturnTypeMap = {
2
+ export type ReflectMethodsReturnTypeMap = {
3
3
  [P in keyof ProxyHandler<object>]-?: ReturnType<Required<ProxyHandler<object>>[P]>;
4
4
  };
5
5
  export declare const reflectMethods: (keyof ProxyHandler<object>)[];
@@ -1,5 +1,5 @@
1
- export declare type Builder<T> = () => T;
2
- export declare type AsyncBuilder<T> = () => Promise<T>;
1
+ export type Builder<T> = () => T;
2
+ export type AsyncBuilder<T> = () => Promise<T>;
3
3
  export declare function singleton<T>(type: any, builder: Builder<T>): T;
4
4
  export declare function singleton<T>(type: any, builder: AsyncBuilder<T>): Promise<T>;
5
5
  export declare function singleton<T>(scope: any, type: any, builder: Builder<T>): T;
package/utils/sort.d.ts CHANGED
@@ -1,5 +1,5 @@
1
- export declare type Comparator<T> = (a: T, b: T) => number;
2
- export declare type AsyncComparator<T> = (a: T, b: T) => number | Promise<number>;
1
+ export type Comparator<T> = (a: T, b: T) => number;
2
+ export type AsyncComparator<T> = (a: T, b: T) => number | Promise<number>;
3
3
  export declare function quickSort<T>(array: T[], comparator?: Comparator<T>, left?: number, right?: number): T[];
4
4
  export declare function quickSortAsync<T>(array: T[], comparator?: AsyncComparator<T>, left?: number, right?: number): Promise<T[]>;
5
5
  export declare function quickSortInPlace<T>(array: T[], comparator?: Comparator<T>, left?: number, right?: number): void;
@@ -1,13 +1,13 @@
1
1
  /// <reference types="node" />
2
2
  declare const nonObjectBufferModeSymbol: unique symbol;
3
3
  declare const nonObjectStringModeSymbol: unique symbol;
4
- export declare type NonObjectMode = NonObjectBufferMode | NonObjectStringMode;
5
- export declare type NonObjectBufferMode = {
4
+ export type NonObjectMode = NonObjectBufferMode | NonObjectStringMode;
5
+ export type NonObjectBufferMode = {
6
6
  readonly [nonObjectBufferModeSymbol]: never;
7
7
  };
8
- export declare type NonObjectStringMode = {
8
+ export type NonObjectStringMode = {
9
9
  readonly [nonObjectStringModeSymbol]: never;
10
10
  };
11
- export declare type NonObjectModeTypes = string | Buffer | Uint8Array;
12
- export declare type Data<T> = T extends NonObjectStringMode ? string : T extends NonObjectBufferMode ? Buffer : (T extends null ? never : T);
11
+ export type NonObjectModeTypes = string | Buffer | Uint8Array;
12
+ export type Data<T> = T extends NonObjectStringMode ? string : T extends NonObjectBufferMode ? Buffer : (T extends null ? never : T);
13
13
  export {};
@@ -1,7 +1,7 @@
1
1
  import type { AbstractConstructor, TypedArray } from "../types";
2
- export declare type InferIsType<T> = T extends (value: any) => value is infer R ? R : never;
3
- export declare type InferIsNotType<ValueType, T> = T extends (value: any) => value is infer R ? Exclude<ValueType, R> : never;
4
- export declare type AssertionMessage = string | (() => string);
2
+ export type InferIsType<T> = T extends (value: any) => value is infer R ? R : never;
3
+ export type InferIsNotType<ValueType, T> = T extends (value: any) => value is infer R ? Exclude<ValueType, R> : never;
4
+ export type AssertionMessage = string | (() => string);
5
5
  export declare function assert(condition: boolean, message?: AssertionMessage): asserts condition;
6
6
  export declare function assertNot(condition: boolean, message?: AssertionMessage): asserts condition;
7
7
  export declare function isType<T>(type: AbstractConstructor<T>, value: any): value is T;
@@ -1,10 +1,10 @@
1
1
  import type { UndefinableJsonObject, UndefinableJsonPrimitive } from '../types';
2
- export declare type UrlBuilderParameterValue = UndefinableJsonPrimitive;
3
- export declare type UrlBuilderParameters = UndefinableJsonObject;
4
- export declare type UrlBuilderOptions = {
2
+ export type UrlBuilderParameterValue = UndefinableJsonPrimitive;
3
+ export type UrlBuilderParameters = UndefinableJsonObject;
4
+ export type UrlBuilderOptions = {
5
5
  arraySeparator?: string;
6
6
  };
7
- export declare type UrlBuilderResult = {
7
+ export type UrlBuilderResult = {
8
8
  parsedUrl: string;
9
9
  parametersRest: UrlBuilderParameters;
10
10
  };
package/web-types.d.ts CHANGED
@@ -1,7 +1,7 @@
1
- export declare type InputType = 'checkbox' | 'color' | 'date' | 'datetime-local' | 'email' | 'file' | 'image' | 'month' | 'number' | 'password' | 'radio' | 'range' | 'search' | 'tel' | 'text' | 'time' | 'url' | 'week';
2
- export declare type InputMode = 'none' | 'text' | 'decimal' | 'numeric' | 'tel' | 'search' | 'email' | 'url';
3
- export declare type InputAutocomplete = 'off' | 'on' | 'name' | 'honorific-prefix' | 'given-name' | 'additional-name' | 'family-name' | 'honorific-suffix' | 'nickname' | 'email' | 'username' | 'new-password' | 'current-password' | 'one-time-code' | 'organization-title' | 'organization' | 'street-address' | 'address-line1' | 'address-line2' | 'address-line3' | 'address-level4' | 'address-level3' | 'address-level2' | 'address-level1' | 'country' | 'country-name' | 'postal-code' | 'cc-name' | 'cc-given-name' | 'cc-additional-name' | 'cc-family-name' | 'cc-number' | 'cc-exp' | 'cc-exp-month' | 'cc-exp-year' | 'cc-csc' | 'cc-type' | 'transaction-currency' | 'transaction-amount' | 'language' | 'bday' | 'bday-day' | 'bday-month' | 'bday-year' | 'sex' | 'tel' | 'tel-country-code' | 'tel-national' | 'tel-area-code' | 'tel-local' | 'tel-extension' | 'impp' | 'url' | 'photo';
4
- export declare type InputAttributes = {
1
+ export type InputType = 'checkbox' | 'color' | 'date' | 'datetime-local' | 'email' | 'file' | 'image' | 'month' | 'number' | 'password' | 'radio' | 'range' | 'search' | 'tel' | 'text' | 'time' | 'url' | 'week';
2
+ export type InputMode = 'none' | 'text' | 'decimal' | 'numeric' | 'tel' | 'search' | 'email' | 'url';
3
+ export type InputAutocomplete = 'off' | 'on' | 'name' | 'honorific-prefix' | 'given-name' | 'additional-name' | 'family-name' | 'honorific-suffix' | 'nickname' | 'email' | 'username' | 'new-password' | 'current-password' | 'one-time-code' | 'organization-title' | 'organization' | 'street-address' | 'address-line1' | 'address-line2' | 'address-line3' | 'address-level4' | 'address-level3' | 'address-level2' | 'address-level1' | 'country' | 'country-name' | 'postal-code' | 'cc-name' | 'cc-given-name' | 'cc-additional-name' | 'cc-family-name' | 'cc-number' | 'cc-exp' | 'cc-exp-month' | 'cc-exp-year' | 'cc-csc' | 'cc-type' | 'transaction-currency' | 'transaction-amount' | 'language' | 'bday' | 'bday-day' | 'bday-month' | 'bday-year' | 'sex' | 'tel' | 'tel-country-code' | 'tel-national' | 'tel-area-code' | 'tel-local' | 'tel-extension' | 'impp' | 'url' | 'photo';
4
+ export type InputAttributes = {
5
5
  accept?: string;
6
6
  autocomplete?: InputAutocomplete;
7
7
  autofocus?: boolean;