rahad-media-downloader 2.1.8 → 2.1.12

Sign up to get free protection for your applications and to get access to all the features.
Files changed (70) hide show
  1. package/.cache/replit/modules/{nodejs-20:v32-20240401-269b323.res → nodejs-20:v36-20240502-f4453db.res} +1 -1
  2. package/.cache/replit/modules/{replit:v8-20240329-787bc7d.res → replit:v9-20240429-0325cbb.res} +1 -1
  3. package/.cache/typescript/5.3/node_modules/.package-lock.json +60 -0
  4. package/.cache/typescript/5.3/node_modules/@types/cookie/LICENSE +21 -0
  5. package/.cache/typescript/5.3/node_modules/@types/cookie/README.md +15 -0
  6. package/.cache/typescript/5.3/node_modules/@types/cookie/index.d.ts +154 -0
  7. package/.cache/typescript/5.3/node_modules/@types/cookie/package.json +30 -0
  8. package/.cache/typescript/5.3/node_modules/@types/domhandler/LICENSE +21 -0
  9. package/.cache/typescript/5.3/node_modules/@types/domhandler/README.md +92 -0
  10. package/.cache/typescript/5.3/node_modules/@types/domhandler/index.d.ts +73 -0
  11. package/.cache/typescript/5.3/node_modules/@types/domhandler/package.json +25 -0
  12. package/.cache/typescript/5.3/node_modules/@types/domutils/LICENSE +21 -0
  13. package/.cache/typescript/5.3/node_modules/@types/domutils/README.md +15 -0
  14. package/.cache/typescript/5.3/node_modules/@types/domutils/index.d.ts +124 -0
  15. package/.cache/typescript/5.3/node_modules/@types/domutils/package.json +27 -0
  16. package/.cache/typescript/5.3/node_modules/@types/htmlparser2/LICENSE +21 -0
  17. package/.cache/typescript/5.3/node_modules/@types/htmlparser2/README.md +15 -0
  18. package/.cache/typescript/5.3/node_modules/@types/htmlparser2/index.d.ts +120 -0
  19. package/.cache/typescript/5.3/node_modules/@types/htmlparser2/package.json +45 -0
  20. package/.cache/typescript/5.3/node_modules/@types/psl/LICENSE +21 -0
  21. package/.cache/typescript/5.3/node_modules/@types/psl/README.md +52 -0
  22. package/.cache/typescript/5.3/node_modules/@types/psl/index.d.ts +33 -0
  23. package/.cache/typescript/5.3/node_modules/@types/psl/package.json +25 -0
  24. package/.cache/typescript/5.3/node_modules/@types/qs/LICENSE +21 -0
  25. package/.cache/typescript/5.3/node_modules/@types/qs/README.md +15 -0
  26. package/.cache/typescript/5.3/node_modules/@types/qs/index.d.ts +79 -0
  27. package/.cache/typescript/5.3/node_modules/@types/qs/package.json +65 -0
  28. package/.cache/typescript/5.3/node_modules/domelementtype/LICENSE +11 -0
  29. package/.cache/typescript/5.3/node_modules/domelementtype/index.js +15 -0
  30. package/.cache/typescript/5.3/node_modules/domelementtype/package.json +16 -0
  31. package/.cache/typescript/5.3/node_modules/domelementtype/readme.md +1 -0
  32. package/.cache/typescript/5.3/node_modules/domhandler/.travis.yml +6 -0
  33. package/.cache/typescript/5.3/node_modules/domhandler/LICENSE +11 -0
  34. package/.cache/typescript/5.3/node_modules/domhandler/index.js +217 -0
  35. package/.cache/typescript/5.3/node_modules/domhandler/lib/element.js +20 -0
  36. package/.cache/typescript/5.3/node_modules/domhandler/lib/node.js +44 -0
  37. package/.cache/typescript/5.3/node_modules/domhandler/package.json +41 -0
  38. package/.cache/typescript/5.3/node_modules/domhandler/readme.md +116 -0
  39. package/.cache/typescript/5.3/node_modules/domhandler/test/cases/01-basic.json +57 -0
  40. package/.cache/typescript/5.3/node_modules/domhandler/test/cases/02-single_tag_1.json +21 -0
  41. package/.cache/typescript/5.3/node_modules/domhandler/test/cases/03-single_tag_2.json +21 -0
  42. package/.cache/typescript/5.3/node_modules/domhandler/test/cases/04-unescaped_in_script.json +27 -0
  43. package/.cache/typescript/5.3/node_modules/domhandler/test/cases/05-tags_in_comment.json +18 -0
  44. package/.cache/typescript/5.3/node_modules/domhandler/test/cases/06-comment_in_script.json +18 -0
  45. package/.cache/typescript/5.3/node_modules/domhandler/test/cases/07-unescaped_in_style.json +20 -0
  46. package/.cache/typescript/5.3/node_modules/domhandler/test/cases/08-extra_spaces_in_tag.json +20 -0
  47. package/.cache/typescript/5.3/node_modules/domhandler/test/cases/09-unquoted_attrib.json +20 -0
  48. package/.cache/typescript/5.3/node_modules/domhandler/test/cases/10-singular_attribute.json +15 -0
  49. package/.cache/typescript/5.3/node_modules/domhandler/test/cases/11-text_outside_tags.json +40 -0
  50. package/.cache/typescript/5.3/node_modules/domhandler/test/cases/12-text_only.json +11 -0
  51. package/.cache/typescript/5.3/node_modules/domhandler/test/cases/13-comment_in_text.json +19 -0
  52. package/.cache/typescript/5.3/node_modules/domhandler/test/cases/14-comment_in_text_in_script.json +18 -0
  53. package/.cache/typescript/5.3/node_modules/domhandler/test/cases/15-non-verbose.json +22 -0
  54. package/.cache/typescript/5.3/node_modules/domhandler/test/cases/16-normalize_whitespace.json +47 -0
  55. package/.cache/typescript/5.3/node_modules/domhandler/test/cases/17-xml_namespace.json +18 -0
  56. package/.cache/typescript/5.3/node_modules/domhandler/test/cases/18-enforce_empty_tags.json +16 -0
  57. package/.cache/typescript/5.3/node_modules/domhandler/test/cases/19-ignore_empty_tags.json +20 -0
  58. package/.cache/typescript/5.3/node_modules/domhandler/test/cases/20-template_script_tags.json +20 -0
  59. package/.cache/typescript/5.3/node_modules/domhandler/test/cases/21-conditional_comments.json +15 -0
  60. package/.cache/typescript/5.3/node_modules/domhandler/test/cases/22-lowercase_tags.json +41 -0
  61. package/.cache/typescript/5.3/node_modules/domhandler/test/cases/23-dom-lvl1.json +131 -0
  62. package/.cache/typescript/5.3/node_modules/domhandler/test/cases/24-with-start-indices.json +85 -0
  63. package/.cache/typescript/5.3/node_modules/domhandler/test/cases/25-with-end-indices.json +86 -0
  64. package/.cache/typescript/5.3/node_modules/domhandler/test/tests.js +60 -0
  65. package/.cache/typescript/5.3/package-lock.json +64 -0
  66. package/.cache/typescript/5.3/package.json +1 -1
  67. package/README.md +103 -18
  68. package/index.js +1 -1
  69. package/package.json +34 -4
  70. package/test.js +0 -35
@@ -1 +1 @@
1
- {"type":"resolve","resolvedModuleId":"nodejs-20:v32-20240401-269b323","inputHash":"","resolutionPath":["nodejs-20:v8-20230920-bd784b9","nodejs-20:v9-20231020-a3526c9","nodejs-20:v10-20231103-2b03dda","nodejs-20:v11-20231122-8e4093b","nodejs-20:v12-20231130-57acee0","nodejs-20:v13-20231201-3b22c78","nodejs-20:v14-20231206-9a12353","nodejs-20:v15-20231206-d8b5d0b","nodejs-20:v16-20231207-cf9ab20","nodejs-20:v17-20231207-25d440f","nodejs-20:v18-20231211-ac14ad7","nodejs-20:v19-20231216-fb57c71","nodejs-20:v20-20231219-faac932","nodejs-20:v21-20240102-fd07a42","nodejs-20:v22-20240103-2da4911","nodejs-20:v23-20240116-9f73277","nodejs-20:v24-20240117-0bd73cd","nodejs-20:v25-20240206-fdbd396","nodejs-20:v26-20240209-9e3a339","nodejs-20:v27-20240213-5e75727","nodejs-20:v28-20240213-3f08513","nodejs-20:v29-20240315-3def760","nodejs-20:v30-20240319-38caddd","nodejs-20:v31-20240329-787bc7d","nodejs-20:v32-20240401-269b323"],"error":"","Changed":true}
1
+ {"type":"resolve","resolvedModuleId":"nodejs-20:v36-20240502-f4453db","inputHash":"","resolutionPath":["nodejs-20:v8-20230920-bd784b9","nodejs-20:v9-20231020-a3526c9","nodejs-20:v10-20231103-2b03dda","nodejs-20:v11-20231122-8e4093b","nodejs-20:v12-20231130-57acee0","nodejs-20:v13-20231201-3b22c78","nodejs-20:v14-20231206-9a12353","nodejs-20:v15-20231206-d8b5d0b","nodejs-20:v16-20231207-cf9ab20","nodejs-20:v17-20231207-25d440f","nodejs-20:v18-20231211-ac14ad7","nodejs-20:v19-20231216-fb57c71","nodejs-20:v20-20231219-faac932","nodejs-20:v21-20240102-fd07a42","nodejs-20:v22-20240103-2da4911","nodejs-20:v23-20240116-9f73277","nodejs-20:v24-20240117-0bd73cd","nodejs-20:v25-20240206-fdbd396","nodejs-20:v26-20240209-9e3a339","nodejs-20:v27-20240213-5e75727","nodejs-20:v28-20240213-3f08513","nodejs-20:v29-20240315-3def760","nodejs-20:v30-20240319-38caddd","nodejs-20:v31-20240329-787bc7d","nodejs-20:v32-20240401-269b323","nodejs-20:v33-20240429-4b1b00e","nodejs-20:v34-20240429-0325cbb","nodejs-20:v35-20240502-5b9002a","nodejs-20:v36-20240502-f4453db"],"error":"","Changed":true}
@@ -1 +1 @@
1
- {"type":"resolve","resolvedModuleId":"replit:v8-20240329-787bc7d","inputHash":"","resolutionPath":["replit","replit:v1-20231211-d5ddcff","replit:v2-20240117-0bd73cd","replit:v3-20240123-c72e35a","replit:v4-20240206-fdbd396","replit:v5-20240209-9e3a339","replit:v6-20240315-3def760","replit:v7-20240319-38caddd","replit:v8-20240329-787bc7d"],"error":"","Changed":true}
1
+ {"type":"resolve","resolvedModuleId":"replit:v9-20240429-0325cbb","inputHash":"","resolutionPath":["replit","replit:v1-20231211-d5ddcff","replit:v2-20240117-0bd73cd","replit:v3-20240123-c72e35a","replit:v4-20240206-fdbd396","replit:v5-20240209-9e3a339","replit:v6-20240315-3def760","replit:v7-20240319-38caddd","replit:v8-20240329-787bc7d","replit:v9-20240429-0325cbb"],"error":"","Changed":true}
@@ -18,6 +18,39 @@
18
18
  "@types/node": "*"
19
19
  }
20
20
  },
21
+ "node_modules/@types/cookie": {
22
+ "version": "0.6.0",
23
+ "resolved": "https://registry.npmjs.org/@types/cookie/-/cookie-0.6.0.tgz",
24
+ "integrity": "sha512-4Kh9a6B2bQciAhf7FSuMRRkUWecJgJu9nPnx3yzpsfXX/c50REIqpHY4C82bXP90qrLtXtkDxTZosYO3UpOwlA==",
25
+ "dev": true
26
+ },
27
+ "node_modules/@types/domhandler": {
28
+ "version": "2.4.5",
29
+ "resolved": "https://registry.npmjs.org/@types/domhandler/-/domhandler-2.4.5.tgz",
30
+ "integrity": "sha512-lANhC2grmFG1gBac/8sDAKdIXx+TzAdkJIAjEOSMA+qW3297ybACEbacJnG15aNYfrzDO6fdcoouokqAKsy6aQ==",
31
+ "dev": true
32
+ },
33
+ "node_modules/@types/domutils": {
34
+ "version": "1.7.8",
35
+ "resolved": "https://registry.npmjs.org/@types/domutils/-/domutils-1.7.8.tgz",
36
+ "integrity": "sha512-iZGboDV79ibrO3D625p9yD+VgmMDnyJocdIRJvu9Xz66R8SHfOY/XNgdjY5SFoFiLgILceVfSLt7IUhlk1Vhhg==",
37
+ "dev": true,
38
+ "dependencies": {
39
+ "@types/domhandler": "^2.4.0"
40
+ }
41
+ },
42
+ "node_modules/@types/htmlparser2": {
43
+ "version": "3.10.7",
44
+ "resolved": "https://registry.npmjs.org/@types/htmlparser2/-/htmlparser2-3.10.7.tgz",
45
+ "integrity": "sha512-ycBs4PNr9rY9XFFp4WkP+M1UcO49ahn0+9b24cmIY6KWy0w35rW0G8+JTTe9Rp6Wnyqn5SEHZrhCBMa0TIOxBw==",
46
+ "dev": true,
47
+ "dependencies": {
48
+ "@types/domhandler": "^2.4.3",
49
+ "@types/domutils": "*",
50
+ "@types/node": "*",
51
+ "domhandler": "^2.4.0"
52
+ }
53
+ },
21
54
  "node_modules/@types/jsdom": {
22
55
  "version": "21.1.6",
23
56
  "resolved": "https://registry.npmjs.org/@types/jsdom/-/jsdom-21.1.6.tgz",
@@ -48,6 +81,18 @@
48
81
  "form-data": "^4.0.0"
49
82
  }
50
83
  },
84
+ "node_modules/@types/psl": {
85
+ "version": "1.1.3",
86
+ "resolved": "https://registry.npmjs.org/@types/psl/-/psl-1.1.3.tgz",
87
+ "integrity": "sha512-Iu174JHfLd7i/XkXY6VDrqSlPvTDQOtQI7wNAXKKOAADJ9TduRLkNdMgjGiMxSttUIZnomv81JAbAbC0DhggxA==",
88
+ "dev": true
89
+ },
90
+ "node_modules/@types/qs": {
91
+ "version": "6.9.15",
92
+ "resolved": "https://registry.npmjs.org/@types/qs/-/qs-6.9.15.tgz",
93
+ "integrity": "sha512-uXHQKES6DQKKCLh441Xv/dwxOq1TVS3JPUMlEqoEglvlhR6Mxnlew/Xq/LRVHpLyk7iK3zODe1qYHIMltO7XGg==",
94
+ "dev": true
95
+ },
51
96
  "node_modules/@types/request": {
52
97
  "version": "2.48.12",
53
98
  "resolved": "https://registry.npmjs.org/@types/request/-/request-2.48.12.tgz",
@@ -107,6 +152,21 @@
107
152
  "node": ">=0.4.0"
108
153
  }
109
154
  },
155
+ "node_modules/domelementtype": {
156
+ "version": "1.3.1",
157
+ "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-1.3.1.tgz",
158
+ "integrity": "sha512-BSKB+TSpMpFI/HOxCNr1O8aMOTZ8hT3pM3GQ0w/mWRmkhEDSFJkkyzz4XQsBV44BChwGkrDfMyjVD0eA2aFV3w==",
159
+ "dev": true
160
+ },
161
+ "node_modules/domhandler": {
162
+ "version": "2.4.2",
163
+ "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-2.4.2.tgz",
164
+ "integrity": "sha512-JiK04h0Ht5u/80fdLMCEmV4zkNh2BcoMFBmZ/91WtYZ8qVXSKjiw7fXMgFPnHcSZgOo3XdinHvmnDUeMf5R4wA==",
165
+ "dev": true,
166
+ "dependencies": {
167
+ "domelementtype": "1"
168
+ }
169
+ },
110
170
  "node_modules/entities": {
111
171
  "version": "4.5.0",
112
172
  "resolved": "https://registry.npmjs.org/entities/-/entities-4.5.0.tgz",
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) Microsoft Corporation.
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
@@ -0,0 +1,15 @@
1
+ # Installation
2
+ > `npm install --save @types/cookie`
3
+
4
+ # Summary
5
+ This package contains type definitions for cookie (https://github.com/jshttp/cookie).
6
+
7
+ # Details
8
+ Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/cookie.
9
+
10
+ ### Additional Details
11
+ * Last updated: Sun, 26 Nov 2023 22:07:01 GMT
12
+ * Dependencies: none
13
+
14
+ # Credits
15
+ These definitions were written by [Pine Mizune](https://github.com/pine), and [Piotr Błażejewicz](https://github.com/peterblazejewicz).
@@ -0,0 +1,154 @@
1
+ /**
2
+ * Basic HTTP cookie parser and serializer for HTTP servers.
3
+ */
4
+
5
+ /**
6
+ * Additional serialization options
7
+ */
8
+ export interface CookieSerializeOptions {
9
+ /**
10
+ * Specifies the value for the {@link https://tools.ietf.org/html/rfc6265#section-5.2.3|Domain Set-Cookie attribute}. By default, no
11
+ * domain is set, and most clients will consider the cookie to apply to only
12
+ * the current domain.
13
+ */
14
+ domain?: string | undefined;
15
+
16
+ /**
17
+ * Specifies a function that will be used to encode a cookie's value. Since
18
+ * value of a cookie has a limited character set (and must be a simple
19
+ * string), this function can be used to encode a value into a string suited
20
+ * for a cookie's value.
21
+ *
22
+ * The default function is the global `encodeURIComponent`, which will
23
+ * encode a JavaScript string into UTF-8 byte sequences and then URL-encode
24
+ * any that fall outside of the cookie range.
25
+ */
26
+ encode?(value: string): string;
27
+
28
+ /**
29
+ * Specifies the `Date` object to be the value for the {@link https://tools.ietf.org/html/rfc6265#section-5.2.1|`Expires` `Set-Cookie` attribute}. By default,
30
+ * no expiration is set, and most clients will consider this a "non-persistent cookie" and will delete
31
+ * it on a condition like exiting a web browser application.
32
+ *
33
+ * *Note* the {@link https://tools.ietf.org/html/rfc6265#section-5.3|cookie storage model specification}
34
+ * states that if both `expires` and `maxAge` are set, then `maxAge` takes precedence, but it is
35
+ * possible not all clients by obey this, so if both are set, they should
36
+ * point to the same date and time.
37
+ */
38
+ expires?: Date | undefined;
39
+ /**
40
+ * Specifies the boolean value for the {@link https://tools.ietf.org/html/rfc6265#section-5.2.6|`HttpOnly` `Set-Cookie` attribute}.
41
+ * When truthy, the `HttpOnly` attribute is set, otherwise it is not. By
42
+ * default, the `HttpOnly` attribute is not set.
43
+ *
44
+ * *Note* be careful when setting this to true, as compliant clients will
45
+ * not allow client-side JavaScript to see the cookie in `document.cookie`.
46
+ */
47
+ httpOnly?: boolean | undefined;
48
+ /**
49
+ * Specifies the number (in seconds) to be the value for the `Max-Age`
50
+ * `Set-Cookie` attribute. The given number will be converted to an integer
51
+ * by rounding down. By default, no maximum age is set.
52
+ *
53
+ * *Note* the {@link https://tools.ietf.org/html/rfc6265#section-5.3|cookie storage model specification}
54
+ * states that if both `expires` and `maxAge` are set, then `maxAge` takes precedence, but it is
55
+ * possible not all clients by obey this, so if both are set, they should
56
+ * point to the same date and time.
57
+ */
58
+ maxAge?: number | undefined;
59
+ /**
60
+ * Specifies the `boolean` value for the [`Partitioned` `Set-Cookie`](rfc-cutler-httpbis-partitioned-cookies)
61
+ * attribute. When truthy, the `Partitioned` attribute is set, otherwise it is not. By default, the
62
+ * `Partitioned` attribute is not set.
63
+ *
64
+ * **note** This is an attribute that has not yet been fully standardized, and may change in the future.
65
+ * This also means many clients may ignore this attribute until they understand it.
66
+ *
67
+ * More information about can be found in [the proposal](https://github.com/privacycg/CHIPS)
68
+ */
69
+ partitioned?: boolean | undefined;
70
+ /**
71
+ * Specifies the value for the {@link https://tools.ietf.org/html/rfc6265#section-5.2.4|`Path` `Set-Cookie` attribute}.
72
+ * By default, the path is considered the "default path".
73
+ */
74
+ path?: string | undefined;
75
+ /**
76
+ * Specifies the `string` to be the value for the [`Priority` `Set-Cookie` attribute][rfc-west-cookie-priority-00-4.1].
77
+ *
78
+ * - `'low'` will set the `Priority` attribute to `Low`.
79
+ * - `'medium'` will set the `Priority` attribute to `Medium`, the default priority when not set.
80
+ * - `'high'` will set the `Priority` attribute to `High`.
81
+ *
82
+ * More information about the different priority levels can be found in
83
+ * [the specification][rfc-west-cookie-priority-00-4.1].
84
+ *
85
+ * **note** This is an attribute that has not yet been fully standardized, and may change in the future.
86
+ * This also means many clients may ignore this attribute until they understand it.
87
+ */
88
+ priority?: "low" | "medium" | "high" | undefined;
89
+ /**
90
+ * Specifies the boolean or string to be the value for the {@link https://tools.ietf.org/html/draft-ietf-httpbis-rfc6265bis-03#section-4.1.2.7|`SameSite` `Set-Cookie` attribute}.
91
+ *
92
+ * - `true` will set the `SameSite` attribute to `Strict` for strict same
93
+ * site enforcement.
94
+ * - `false` will not set the `SameSite` attribute.
95
+ * - `'lax'` will set the `SameSite` attribute to Lax for lax same site
96
+ * enforcement.
97
+ * - `'strict'` will set the `SameSite` attribute to Strict for strict same
98
+ * site enforcement.
99
+ * - `'none'` will set the SameSite attribute to None for an explicit
100
+ * cross-site cookie.
101
+ *
102
+ * More information about the different enforcement levels can be found in {@link https://tools.ietf.org/html/draft-ietf-httpbis-rfc6265bis-03#section-4.1.2.7|the specification}.
103
+ *
104
+ * *note* This is an attribute that has not yet been fully standardized, and may change in the future. This also means many clients may ignore this attribute until they understand it.
105
+ */
106
+ sameSite?: true | false | "lax" | "strict" | "none" | undefined;
107
+ /**
108
+ * Specifies the boolean value for the {@link https://tools.ietf.org/html/rfc6265#section-5.2.5|`Secure` `Set-Cookie` attribute}. When truthy, the
109
+ * `Secure` attribute is set, otherwise it is not. By default, the `Secure` attribute is not set.
110
+ *
111
+ * *Note* be careful when setting this to `true`, as compliant clients will
112
+ * not send the cookie back to the server in the future if the browser does
113
+ * not have an HTTPS connection.
114
+ */
115
+ secure?: boolean | undefined;
116
+ }
117
+
118
+ /**
119
+ * Additional parsing options
120
+ */
121
+ export interface CookieParseOptions {
122
+ /**
123
+ * Specifies a function that will be used to decode a cookie's value. Since
124
+ * the value of a cookie has a limited character set (and must be a simple
125
+ * string), this function can be used to decode a previously-encoded cookie
126
+ * value into a JavaScript string or other object.
127
+ *
128
+ * The default function is the global `decodeURIComponent`, which will decode
129
+ * any URL-encoded sequences into their byte representations.
130
+ *
131
+ * *Note* if an error is thrown from this function, the original, non-decoded
132
+ * cookie value will be returned as the cookie's value.
133
+ */
134
+ decode?(value: string): string;
135
+ }
136
+
137
+ /**
138
+ * Parse an HTTP Cookie header string and returning an object of all cookie
139
+ * name-value pairs.
140
+ *
141
+ * @param str the string representing a `Cookie` header value
142
+ * @param [options] object containing parsing options
143
+ */
144
+ export function parse(str: string, options?: CookieParseOptions): Record<string, string>;
145
+
146
+ /**
147
+ * Serialize a cookie name-value pair into a `Set-Cookie` header string.
148
+ *
149
+ * @param name the name for the cookie
150
+ * @param value value to set the cookie to
151
+ * @param [options] object containing serialization options
152
+ * @throws {TypeError} when `maxAge` options is invalid
153
+ */
154
+ export function serialize(name: string, value: string, options?: CookieSerializeOptions): string;
@@ -0,0 +1,30 @@
1
+ {
2
+ "name": "@types/cookie",
3
+ "version": "0.6.0",
4
+ "description": "TypeScript definitions for cookie",
5
+ "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/cookie",
6
+ "license": "MIT",
7
+ "contributors": [
8
+ {
9
+ "name": "Pine Mizune",
10
+ "githubUsername": "pine",
11
+ "url": "https://github.com/pine"
12
+ },
13
+ {
14
+ "name": "Piotr Błażejewicz",
15
+ "githubUsername": "peterblazejewicz",
16
+ "url": "https://github.com/peterblazejewicz"
17
+ }
18
+ ],
19
+ "main": "",
20
+ "types": "index.d.ts",
21
+ "repository": {
22
+ "type": "git",
23
+ "url": "https://github.com/DefinitelyTyped/DefinitelyTyped.git",
24
+ "directory": "types/cookie"
25
+ },
26
+ "scripts": {},
27
+ "dependencies": {},
28
+ "typesPublisherContentHash": "0fbdf9c886fb40c8dc7677b8b7d0f9e02ac5235e163d90244a4fb9004736a575",
29
+ "typeScriptVersion": "4.5"
30
+ }
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) Microsoft Corporation.
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
@@ -0,0 +1,92 @@
1
+ # Installation
2
+ > `npm install --save @types/domhandler`
3
+
4
+ # Summary
5
+ This package contains type definitions for domhandler (https://github.com/fb55/DomHandler#readme).
6
+
7
+ # Details
8
+ Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/domhandler.
9
+ ## [index.d.ts](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/domhandler/index.d.ts)
10
+ ````ts
11
+ export interface DomHandlerOptions {
12
+ /***
13
+ * Indicates whether the whitespace in text nodes should be normalized
14
+ * (= all whitespace should be replaced with single spaces). The default value is "false".
15
+ */
16
+ normalizeWhitespace?: boolean | undefined;
17
+
18
+ /***
19
+ * Adds DOM level 1 properties to all elements.
20
+ */
21
+ withDomLvl1?: boolean | undefined;
22
+
23
+ /***
24
+ * Indicates whether a startIndex property will be added to nodes.
25
+ * When the parser is used in a non-streaming fashion, startIndex is an integer
26
+ * indicating the position of the start of the node in the document.
27
+ * The default value is "false".
28
+ */
29
+ withStartIndices?: boolean | undefined;
30
+
31
+ /***
32
+ * Indicates whether a endIndex property will be added to nodes.
33
+ * When the parser is used in a non-streaming fashion, endIndex is an integer
34
+ * indicating the position of the end of the node in the document.
35
+ * The default value is "false".
36
+ */
37
+ withEndIndices?: boolean | undefined;
38
+ }
39
+
40
+ export interface DomElement {
41
+ attribs?: { [s: string]: string } | undefined;
42
+ children?: DomElement[] | undefined;
43
+ data?: any;
44
+ name?: string | undefined;
45
+ next?: DomElement | undefined;
46
+ parent?: DomElement | undefined;
47
+ prev?: DomElement | undefined;
48
+ type?: string | undefined;
49
+ }
50
+
51
+ export interface Element extends DomElement {
52
+ name: string;
53
+ }
54
+
55
+ export interface Node extends DomElement {
56
+ readonly firstChild: DomElement;
57
+ readonly lastChild: DomElement;
58
+ readonly nodeType: number;
59
+ }
60
+
61
+ export class DomHandler {
62
+ constructor(callback: (error: any, dom: DomElement[]) => any, options?: DomHandlerOptions);
63
+
64
+ onparserinit(parser: any): void;
65
+
66
+ /***
67
+ * Resets the handler back to starting state
68
+ */
69
+ onreset(): void;
70
+
71
+ /***
72
+ * Signals the handler that parsing is done
73
+ */
74
+ onend(): void;
75
+ onerror(error: Error): void;
76
+ onclosetag(): void;
77
+ onopentag(name: string, attribs: { [s: string]: string }): void;
78
+ ontext(data: string): void;
79
+ oncomment(data: string): void;
80
+ oncdatastart(): void;
81
+ oncommentend(): void;
82
+ onprocessinginstruction(name: string, data: string): void;
83
+ }
84
+
85
+ ````
86
+
87
+ ### Additional Details
88
+ * Last updated: Mon, 06 Nov 2023 22:41:05 GMT
89
+ * Dependencies: none
90
+
91
+ # Credits
92
+ These definitions were written by [Johan Davidsson](https://github.com/johandavidson).
@@ -0,0 +1,73 @@
1
+ export interface DomHandlerOptions {
2
+ /***
3
+ * Indicates whether the whitespace in text nodes should be normalized
4
+ * (= all whitespace should be replaced with single spaces). The default value is "false".
5
+ */
6
+ normalizeWhitespace?: boolean | undefined;
7
+
8
+ /***
9
+ * Adds DOM level 1 properties to all elements.
10
+ */
11
+ withDomLvl1?: boolean | undefined;
12
+
13
+ /***
14
+ * Indicates whether a startIndex property will be added to nodes.
15
+ * When the parser is used in a non-streaming fashion, startIndex is an integer
16
+ * indicating the position of the start of the node in the document.
17
+ * The default value is "false".
18
+ */
19
+ withStartIndices?: boolean | undefined;
20
+
21
+ /***
22
+ * Indicates whether a endIndex property will be added to nodes.
23
+ * When the parser is used in a non-streaming fashion, endIndex is an integer
24
+ * indicating the position of the end of the node in the document.
25
+ * The default value is "false".
26
+ */
27
+ withEndIndices?: boolean | undefined;
28
+ }
29
+
30
+ export interface DomElement {
31
+ attribs?: { [s: string]: string } | undefined;
32
+ children?: DomElement[] | undefined;
33
+ data?: any;
34
+ name?: string | undefined;
35
+ next?: DomElement | undefined;
36
+ parent?: DomElement | undefined;
37
+ prev?: DomElement | undefined;
38
+ type?: string | undefined;
39
+ }
40
+
41
+ export interface Element extends DomElement {
42
+ name: string;
43
+ }
44
+
45
+ export interface Node extends DomElement {
46
+ readonly firstChild: DomElement;
47
+ readonly lastChild: DomElement;
48
+ readonly nodeType: number;
49
+ }
50
+
51
+ export class DomHandler {
52
+ constructor(callback: (error: any, dom: DomElement[]) => any, options?: DomHandlerOptions);
53
+
54
+ onparserinit(parser: any): void;
55
+
56
+ /***
57
+ * Resets the handler back to starting state
58
+ */
59
+ onreset(): void;
60
+
61
+ /***
62
+ * Signals the handler that parsing is done
63
+ */
64
+ onend(): void;
65
+ onerror(error: Error): void;
66
+ onclosetag(): void;
67
+ onopentag(name: string, attribs: { [s: string]: string }): void;
68
+ ontext(data: string): void;
69
+ oncomment(data: string): void;
70
+ oncdatastart(): void;
71
+ oncommentend(): void;
72
+ onprocessinginstruction(name: string, data: string): void;
73
+ }
@@ -0,0 +1,25 @@
1
+ {
2
+ "name": "@types/domhandler",
3
+ "version": "2.4.5",
4
+ "description": "TypeScript definitions for domhandler",
5
+ "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/domhandler",
6
+ "license": "MIT",
7
+ "contributors": [
8
+ {
9
+ "name": "Johan Davidsson",
10
+ "githubUsername": "johandavidson",
11
+ "url": "https://github.com/johandavidson"
12
+ }
13
+ ],
14
+ "main": "",
15
+ "types": "index.d.ts",
16
+ "repository": {
17
+ "type": "git",
18
+ "url": "https://github.com/DefinitelyTyped/DefinitelyTyped.git",
19
+ "directory": "types/domhandler"
20
+ },
21
+ "scripts": {},
22
+ "dependencies": {},
23
+ "typesPublisherContentHash": "60a0dea4ceaa8d3a2845f5b3a5f65cca135472055a4143248af267f9fd234f68",
24
+ "typeScriptVersion": "4.5"
25
+ }
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) Microsoft Corporation.
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
@@ -0,0 +1,15 @@
1
+ # Installation
2
+ > `npm install --save @types/domutils`
3
+
4
+ # Summary
5
+ This package contains type definitions for domutils (https://github.com/FB55/domutils#readme).
6
+
7
+ # Details
8
+ Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/domutils.
9
+
10
+ ### Additional Details
11
+ * Last updated: Mon, 06 Nov 2023 22:41:05 GMT
12
+ * Dependencies: [@types/domhandler](https://npmjs.com/package/@types/domhandler)
13
+
14
+ # Credits
15
+ These definitions were written by [Johan Davidsson](https://github.com/johandavidson).