@4players/odin-common 3.2.0 → 4.0.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 (97) hide show
  1. package/README.md +11 -5
  2. package/mod.d.ts +26 -0
  3. package/mod.js +1182 -0
  4. package/mod.mjs +1065 -0
  5. package/package.json +6 -30
  6. package/{lib/plugin → plugin}/api.d.ts +7 -7
  7. package/{lib/rpc → rpc}/commands.d.ts +99 -99
  8. package/rpc/notifications.d.ts +1626 -0
  9. package/{lib/schema → schema}/channels.d.ts +1 -1
  10. package/schema/media.d.ts +122 -0
  11. package/schema/message.d.ts +12 -0
  12. package/schema/peer.d.ts +226 -0
  13. package/schema/room.d.ts +1673 -0
  14. package/{lib/schema → schema}/serialization.d.ts +2 -2
  15. package/{lib/schema → schema}/token.d.ts +31 -31
  16. package/{lib/schema → schema}/webrtc.d.ts +21 -21
  17. package/{lib/utility → utility}/base64.d.ts +1 -1
  18. package/utility/bytearray.d.ts +4 -0
  19. package/{lib/utility → utility}/codec.d.ts +1 -1
  20. package/utility/json.d.ts +2 -0
  21. package/{lib/utility → utility}/log.d.ts +3 -3
  22. package/{lib/utility → utility}/result.d.ts +2 -2
  23. package/{lib/utility → utility}/selector.d.ts +2 -2
  24. package/{lib/utility → utility}/sleep.d.ts +1 -1
  25. package/{lib/utility → utility}/url.d.ts +1 -1
  26. package/utility/validation.d.ts +10 -0
  27. package/eslint.config.mjs +0 -30
  28. package/lib/cjs/index.js +0 -44
  29. package/lib/cjs/plugin/api.js +0 -19
  30. package/lib/cjs/rpc/commands.js +0 -96
  31. package/lib/cjs/rpc/notifications.js +0 -39
  32. package/lib/cjs/schema/channels.js +0 -44
  33. package/lib/cjs/schema/media.js +0 -25
  34. package/lib/cjs/schema/message.js +0 -10
  35. package/lib/cjs/schema/peer.js +0 -34
  36. package/lib/cjs/schema/room.js +0 -136
  37. package/lib/cjs/schema/serialization.js +0 -15
  38. package/lib/cjs/schema/token.js +0 -33
  39. package/lib/cjs/schema/webrtc.js +0 -23
  40. package/lib/cjs/tsconfig.cjs.tsbuildinfo +0 -1
  41. package/lib/cjs/utility/base64.js +0 -29
  42. package/lib/cjs/utility/bytearray.js +0 -28
  43. package/lib/cjs/utility/codec.js +0 -89
  44. package/lib/cjs/utility/environment.js +0 -32
  45. package/lib/cjs/utility/iterable.js +0 -10
  46. package/lib/cjs/utility/json.js +0 -6
  47. package/lib/cjs/utility/log.js +0 -224
  48. package/lib/cjs/utility/msgpack.js +0 -11
  49. package/lib/cjs/utility/result.js +0 -31
  50. package/lib/cjs/utility/selector.js +0 -18
  51. package/lib/cjs/utility/sleep.js +0 -27
  52. package/lib/cjs/utility/strand.js +0 -38
  53. package/lib/cjs/utility/url.js +0 -27
  54. package/lib/cjs/utility/uuid.js +0 -11
  55. package/lib/cjs/utility/validation.js +0 -38
  56. package/lib/esm/index.js +0 -27
  57. package/lib/esm/plugin/api.js +0 -16
  58. package/lib/esm/rpc/commands.js +0 -93
  59. package/lib/esm/rpc/notifications.js +0 -36
  60. package/lib/esm/schema/channels.js +0 -40
  61. package/lib/esm/schema/media.js +0 -22
  62. package/lib/esm/schema/message.js +0 -7
  63. package/lib/esm/schema/peer.js +0 -31
  64. package/lib/esm/schema/room.js +0 -133
  65. package/lib/esm/schema/serialization.js +0 -12
  66. package/lib/esm/schema/token.js +0 -29
  67. package/lib/esm/schema/webrtc.js +0 -20
  68. package/lib/esm/tsconfig.esm.tsbuildinfo +0 -1
  69. package/lib/esm/utility/base64.js +0 -25
  70. package/lib/esm/utility/bytearray.js +0 -24
  71. package/lib/esm/utility/codec.js +0 -85
  72. package/lib/esm/utility/environment.js +0 -24
  73. package/lib/esm/utility/iterable.js +0 -7
  74. package/lib/esm/utility/json.js +0 -3
  75. package/lib/esm/utility/log.js +0 -210
  76. package/lib/esm/utility/msgpack.js +0 -7
  77. package/lib/esm/utility/result.js +0 -23
  78. package/lib/esm/utility/selector.js +0 -14
  79. package/lib/esm/utility/sleep.js +0 -22
  80. package/lib/esm/utility/strand.js +0 -34
  81. package/lib/esm/utility/url.js +0 -23
  82. package/lib/esm/utility/uuid.js +0 -7
  83. package/lib/esm/utility/validation.js +0 -27
  84. package/lib/index.d.ts +0 -27
  85. package/lib/rpc/notifications.d.ts +0 -1626
  86. package/lib/schema/media.d.ts +0 -122
  87. package/lib/schema/message.d.ts +0 -12
  88. package/lib/schema/peer.d.ts +0 -226
  89. package/lib/schema/room.d.ts +0 -1673
  90. package/lib/utility/bytearray.d.ts +0 -4
  91. package/lib/utility/json.d.ts +0 -4
  92. package/lib/utility/msgpack.d.ts +0 -2
  93. package/lib/utility/validation.d.ts +0 -10
  94. /package/{lib/utility → utility}/environment.d.ts +0 -0
  95. /package/{lib/utility → utility}/iterable.d.ts +0 -0
  96. /package/{lib/utility → utility}/strand.d.ts +0 -0
  97. /package/{lib/utility → utility}/uuid.d.ts +0 -0
package/README.md CHANGED
@@ -4,25 +4,31 @@
4
4
  [![npm](https://img.shields.io/npm/l/@4players/odin-common.svg)][license-url]
5
5
  [![npm](https://img.shields.io/npm/dm/@4players/odin-common.svg)][npm-badge-url]
6
6
 
7
- A collection of commonly used type definitions and schemas across ODIN web projects.
7
+ A collection of commonly used type definitions and schemas across ODIN web
8
+ projects.
8
9
 
9
10
  ## Troubleshooting
10
11
 
11
- Contact us through the listed methods below to receive answers to your questions and learn more about ODIN.
12
+ Contact us through the listed methods below to receive answers to your questions
13
+ and learn more about ODIN.
12
14
 
13
15
  ### Discord
14
16
 
15
- Join our official Discord server to chat with us directly and become a part of the 4Players ODIN community.
17
+ Join our official Discord server to chat with us directly and become a part of
18
+ the 4Players ODIN community.
16
19
 
17
20
  [![Join us on Discord](https://www.4players.io/images/join_discord.png)](https://4np.de/discord)
18
21
 
19
22
  ### Twitter
20
23
 
21
- Have a quick question? Tweet us at [@ODIN4Players](https://twitter.com/ODIN4Players) and we’ll help you resolve any issues.
24
+ Have a quick question? Tweet us at
25
+ [@ODIN4Players](https://twitter.com/ODIN4Players) and we’ll help you resolve any
26
+ issues.
22
27
 
23
28
  ### Email
24
29
 
25
- Don’t use Discord or Twitter? Send us an [email](mailto:odin@4players.io) and we’ll get back to you as soon as possible.
30
+ Don’t use Discord or Twitter? Send us an [email](mailto:odin@4players.io) and
31
+ we’ll get back to you as soon as possible.
26
32
 
27
33
  [npm-badge-url]: https://www.npmjs.com/package/@4players/odin-common
28
34
  [license-url]: https://github.com/4Players/odin-sdk-web/blob/master/LICENSE
package/mod.d.ts ADDED
@@ -0,0 +1,26 @@
1
+ export * as zod from "zod";
2
+ export * from "./schema/serialization.ts";
3
+ export * from "./schema/token.ts";
4
+ export * from "./schema/room.ts";
5
+ export * from "./schema/peer.ts";
6
+ export * from "./schema/media.ts";
7
+ export * from "./schema/message.ts";
8
+ export * from "./schema/webrtc.ts";
9
+ export * from "./schema/channels.ts";
10
+ export * from "./rpc/commands.ts";
11
+ export * from "./rpc/notifications.ts";
12
+ export * from "./utility/base64.ts";
13
+ export * from "./utility/bytearray.ts";
14
+ export * from "./utility/codec.ts";
15
+ export * from "./utility/iterable.ts";
16
+ export * from "./utility/environment.ts";
17
+ export * from "./utility/json.ts";
18
+ export * from "./utility/result.ts";
19
+ export * from "./utility/selector.ts";
20
+ export * from "./utility/sleep.ts";
21
+ export * from "./utility/strand.ts";
22
+ export * from "./utility/url.ts";
23
+ export * from "./utility/uuid.ts";
24
+ export * from "./utility/validation.ts";
25
+ export * from "./utility/log.ts";
26
+ export * from "./plugin/api.ts";