@session.js/consts 1.0.2 โ 1.0.4
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/LICENSE +21 -0
- package/README.md +7 -3
- package/dist/index.js +3 -5
- package/package.json +36 -26
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Viktor Shchelochkov <hi@hloth.dev> (https://hloth.dev)
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
CHANGED
|
@@ -14,10 +14,14 @@ Session Desktop & Session.js constants
|
|
|
14
14
|
- `MAX_USERNAME_BYTES`
|
|
15
15
|
- `FEATURE_RELEASE_TIMESTAMPS`
|
|
16
16
|
|
|
17
|
-
## Made for
|
|
17
|
+
## Made for Session.js
|
|
18
18
|
|
|
19
|
-
Use Session messenger programmatically with [Session.js](https://
|
|
19
|
+
Use Session messenger programmatically with [Session.js](https://git.hloth.dev/session.js/client): Session bots, custom Session clients, and more.
|
|
20
20
|
|
|
21
21
|
## Donate
|
|
22
22
|
|
|
23
|
-
[hloth.dev/donate](https://hloth.dev/donate)
|
|
23
|
+
[hloth.dev/donate](https://hloth.dev/donate) ยท Tor: [hlothdevzkti6suoksy7lcy7hmpxnr3msu5waokzaslsi2mnx5ouu4qd.onion/donate](http://hlothdevzkti6suoksy7lcy7hmpxnr3msu5waokzaslsi2mnx5ouu4qd.onion/donate)
|
|
24
|
+
|
|
25
|
+
## License
|
|
26
|
+
|
|
27
|
+
[MIT](./LICENSE)
|
package/dist/index.js
CHANGED
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
// CREDIT: OXEN, Session-Desktop
|
|
2
|
-
// github.com/oxen-io/session-desktop
|
|
3
1
|
const seconds = 1000;
|
|
4
2
|
const minutes = seconds * 60;
|
|
5
3
|
const hours = minutes * 60;
|
|
@@ -36,8 +34,8 @@ export const SWARM_POLLING_TIMEOUT = {
|
|
|
36
34
|
INACTIVE: DURATION.SECONDS * 120,
|
|
37
35
|
};
|
|
38
36
|
export const PROTOCOLS = {
|
|
39
|
-
HTTP:
|
|
40
|
-
HTTPS:
|
|
37
|
+
HTTP: "http:",
|
|
38
|
+
HTTPS: "https:",
|
|
41
39
|
};
|
|
42
40
|
export const CONVERSATION = {
|
|
43
41
|
DEFAULT_MEDIA_FETCH_COUNT: 50,
|
|
@@ -58,7 +56,7 @@ export const VALIDATION = {
|
|
|
58
56
|
MAX_GROUP_NAME_LENGTH: 30,
|
|
59
57
|
CLOSED_GROUP_SIZE_LIMIT: 100,
|
|
60
58
|
};
|
|
61
|
-
export const DEFAULT_RECENT_REACTS = [
|
|
59
|
+
export const DEFAULT_RECENT_REACTS = ["๐", "๐ฅฐ", "๐ข", "๐ก", "๐ฎ", "๐"];
|
|
62
60
|
export const REACT_LIMIT = 6;
|
|
63
61
|
export const MAX_USERNAME_BYTES = 64;
|
|
64
62
|
export const FEATURE_RELEASE_TIMESTAMPS = {
|
package/package.json
CHANGED
|
@@ -1,28 +1,38 @@
|
|
|
1
1
|
{
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
2
|
+
"name": "@session.js/consts",
|
|
3
|
+
"version": "1.0.4",
|
|
4
|
+
"description": "Session Desktop & Session.js constants",
|
|
5
|
+
"homepage": "https://git.hloth.dev/session.js/consts#readme",
|
|
6
|
+
"bugs": {
|
|
7
|
+
"url": "https://git.hloth.dev/session.js/consts/issues"
|
|
8
|
+
},
|
|
9
|
+
"repository": {
|
|
10
|
+
"type": "git",
|
|
11
|
+
"url": "https://git.hloth.dev/session.js/consts.git"
|
|
12
|
+
},
|
|
13
|
+
"funding": "https://hloth.dev/donate",
|
|
14
|
+
"license": "MIT",
|
|
15
|
+
"author": "Viktor Shchelochkov <hi@hloth.dev> (https://hloth.dev)",
|
|
16
|
+
"type": "module",
|
|
17
|
+
"main": "dist/index.js",
|
|
18
|
+
"types": "dist/index.d.ts",
|
|
19
|
+
"files": [
|
|
20
|
+
"dist/index.js",
|
|
21
|
+
"dist/index.d.ts",
|
|
22
|
+
"README.md",
|
|
23
|
+
"LICENSE"
|
|
24
|
+
],
|
|
25
|
+
"scripts": {
|
|
26
|
+
"build": "rm -rf dist && tsc --project tsconfig.build.json"
|
|
27
|
+
},
|
|
28
|
+
"devDependencies": {
|
|
29
|
+
"@eslint/compat": "^2.0.1",
|
|
30
|
+
"@eslint/js": "^9.39.2",
|
|
31
|
+
"eslint-config-prettier": "^10.1.8",
|
|
32
|
+
"prettier": "^3.8.0",
|
|
33
|
+
"typescript-eslint": "^8.53.1"
|
|
34
|
+
},
|
|
35
|
+
"peerDependencies": {
|
|
36
|
+
"typescript": "^5.0.0"
|
|
37
|
+
}
|
|
28
38
|
}
|