@cedx/base 0.6.0 → 0.8.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.
- package/ReadMe.md +1 -1
- package/lib/Data/Pagination.d.ts +30 -13
- package/lib/Data/Pagination.d.ts.map +1 -1
- package/lib/Data/Pagination.js +39 -12
- package/lib/Data/Sort.d.ts +25 -23
- package/lib/Data/Sort.d.ts.map +1 -1
- package/lib/Data/Sort.js +37 -33
- package/lib/{Date.d.ts → DateExtensions.d.ts} +1 -1
- package/lib/DateExtensions.d.ts.map +1 -0
- package/lib/{Html/File.d.ts → FileExtensions.d.ts} +4 -11
- package/lib/FileExtensions.d.ts.map +1 -0
- package/lib/{Html/File.js → FileExtensions.js} +4 -13
- package/lib/Hosting/Environment.d.ts +22 -0
- package/lib/Hosting/Environment.d.ts.map +1 -0
- package/lib/Hosting/Environment.js +17 -0
- package/lib/Hosting/HostEnvironment.d.ts +61 -0
- package/lib/Hosting/HostEnvironment.d.ts.map +1 -0
- package/lib/Hosting/HostEnvironment.js +56 -0
- package/lib/Net/Http/HttpMethod.d.ts +46 -0
- package/lib/Net/Http/HttpMethod.d.ts.map +1 -0
- package/lib/Net/Http/HttpMethod.js +41 -0
- package/lib/Net/Http/StatusCode.d.ts +122 -0
- package/lib/Net/Http/StatusCode.d.ts.map +1 -0
- package/lib/Net/Http/StatusCode.js +117 -0
- package/lib/Net/Mime/DispositionType.d.ts +18 -0
- package/lib/Net/Mime/DispositionType.d.ts.map +1 -0
- package/lib/Net/Mime/DispositionType.js +13 -0
- package/lib/Net/Mime/MediaType.d.ts +151 -0
- package/lib/Net/Mime/MediaType.d.ts.map +1 -0
- package/lib/Net/Mime/MediaType.js +150 -0
- package/lib/{Number.d.ts → NumberExtensions.d.ts} +1 -1
- package/lib/NumberExtensions.d.ts.map +1 -0
- package/lib/{String.d.ts → StringExtensions.d.ts} +1 -1
- package/lib/StringExtensions.d.ts.map +1 -0
- package/lib/{Html → UI}/AppTheme.d.ts +3 -3
- package/lib/UI/AppTheme.d.ts.map +1 -0
- package/lib/{Html → UI}/AppTheme.js +3 -3
- package/lib/UI/{Component.d.ts → Components/ComponentBase.d.ts} +5 -5
- package/lib/UI/Components/ComponentBase.d.ts.map +1 -0
- package/lib/UI/Components/ComponentBase.js +29 -0
- package/lib/UI/{LoadingIndicator.d.ts → Components/LoadingIndicator.d.ts} +1 -2
- package/lib/UI/Components/LoadingIndicator.d.ts.map +1 -0
- package/lib/UI/Components/MenuActivator.d.ts.map +1 -0
- package/lib/UI/Components/OfflineIndicator.d.ts.map +1 -0
- package/lib/UI/Components/ThemeDropdown.d.ts +67 -0
- package/lib/UI/Components/ThemeDropdown.d.ts.map +1 -0
- package/lib/UI/Components/ThemeDropdown.js +140 -0
- package/lib/UI/Context.d.ts.map +1 -0
- package/lib/UI/FormExtensions.d.ts +33 -0
- package/lib/UI/FormExtensions.d.ts.map +1 -0
- package/lib/UI/FormExtensions.js +50 -0
- package/lib/UI/MenuAlignment.d.ts +18 -0
- package/lib/UI/MenuAlignment.d.ts.map +1 -0
- package/lib/UI/MenuAlignment.js +13 -0
- package/lib/{Html → UI}/ViewportScroller.d.ts +1 -1
- package/lib/UI/ViewportScroller.d.ts.map +1 -0
- package/lib/{Html → UI}/ViewportScroller.js +6 -6
- package/package.json +5 -10
- package/src/Client/Data/Pagination.ts +59 -13
- package/src/Client/Data/Sort.ts +40 -35
- package/src/Client/Data/tsconfig.json +1 -1
- package/src/Client/{Html/File.ts → FileExtensions.ts} +4 -14
- package/src/Client/Hosting/Environment.ts +25 -0
- package/src/Client/Hosting/HostEnvironment.ts +86 -0
- package/src/Client/{Abstractions → Hosting}/tsconfig.json +3 -3
- package/src/Client/Net/Http/HttpMethod.ts +55 -0
- package/src/Client/Net/Http/StatusCode.ts +150 -0
- package/src/Client/Net/Mime/DispositionType.ts +20 -0
- package/src/Client/Net/Mime/MediaType.ts +185 -0
- package/src/Client/{DependencyInjection → Net}/tsconfig.json +3 -3
- package/src/Client/{Html → UI}/AppTheme.ts +3 -3
- package/src/Client/UI/Components/ComponentBase.ts +34 -0
- package/src/Client/UI/{LoadingIndicator.ts → Components/LoadingIndicator.ts} +1 -3
- package/src/Client/UI/Components/ThemeDropdown.ts +163 -0
- package/src/Client/UI/FormExtensions.ts +55 -0
- package/src/Client/UI/MenuAlignment.ts +20 -0
- package/src/Client/{Html → UI}/ViewportScroller.ts +6 -6
- package/src/Client/UI/tsconfig.json +2 -6
- package/src/Client/tsconfig.json +2 -4
- package/lib/Abstractions/ILoadingIndicator.d.ts +0 -17
- package/lib/Abstractions/ILoadingIndicator.d.ts.map +0 -1
- package/lib/Abstractions/ILoadingIndicator.js +0 -1
- package/lib/Date.d.ts.map +0 -1
- package/lib/DependencyInjection/Container.d.ts +0 -43
- package/lib/DependencyInjection/Container.d.ts.map +0 -1
- package/lib/DependencyInjection/Container.js +0 -65
- package/lib/Html/AppTheme.d.ts.map +0 -1
- package/lib/Html/Context.d.ts.map +0 -1
- package/lib/Html/File.d.ts.map +0 -1
- package/lib/Html/ViewportScroller.d.ts.map +0 -1
- package/lib/Http/HttpClient.d.ts +0 -68
- package/lib/Http/HttpClient.d.ts.map +0 -1
- package/lib/Http/HttpClient.js +0 -102
- package/lib/Http/HttpError.d.ts +0 -33
- package/lib/Http/HttpError.d.ts.map +0 -1
- package/lib/Http/HttpError.js +0 -66
- package/lib/Http/StatusCodes.d.ts +0 -114
- package/lib/Http/StatusCodes.d.ts.map +0 -1
- package/lib/Http/StatusCodes.js +0 -109
- package/lib/Number.d.ts.map +0 -1
- package/lib/String.d.ts.map +0 -1
- package/lib/UI/Component.d.ts.map +0 -1
- package/lib/UI/Component.js +0 -29
- package/lib/UI/LoadingIndicator.d.ts.map +0 -1
- package/lib/UI/MenuActivator.d.ts.map +0 -1
- package/lib/UI/OfflineIndicator.d.ts.map +0 -1
- package/lib/UI/ThemeDropdown.d.ts +0 -40
- package/lib/UI/ThemeDropdown.d.ts.map +0 -1
- package/lib/UI/ThemeDropdown.js +0 -80
- package/src/Client/Abstractions/ILoadingIndicator.ts +0 -16
- package/src/Client/DependencyInjection/Container.ts +0 -75
- package/src/Client/Html/tsconfig.json +0 -16
- package/src/Client/Http/HttpClient.ts +0 -127
- package/src/Client/Http/HttpError.ts +0 -75
- package/src/Client/Http/StatusCodes.ts +0 -140
- package/src/Client/Http/tsconfig.json +0 -16
- package/src/Client/UI/Component.ts +0 -34
- package/src/Client/UI/ThemeDropdown.ts +0 -104
- /package/lib/{Date.js → DateExtensions.js} +0 -0
- /package/lib/{Number.js → NumberExtensions.js} +0 -0
- /package/lib/{String.js → StringExtensions.js} +0 -0
- /package/lib/UI/{LoadingIndicator.js → Components/LoadingIndicator.js} +0 -0
- /package/lib/UI/{MenuActivator.d.ts → Components/MenuActivator.d.ts} +0 -0
- /package/lib/UI/{MenuActivator.js → Components/MenuActivator.js} +0 -0
- /package/lib/UI/{OfflineIndicator.d.ts → Components/OfflineIndicator.d.ts} +0 -0
- /package/lib/UI/{OfflineIndicator.js → Components/OfflineIndicator.js} +0 -0
- /package/lib/{Html → UI}/Context.d.ts +0 -0
- /package/lib/{Html → UI}/Context.js +0 -0
- /package/src/Client/{Date.ts → DateExtensions.ts} +0 -0
- /package/src/Client/{Number.ts → NumberExtensions.ts} +0 -0
- /package/src/Client/{String.ts → StringExtensions.ts} +0 -0
- /package/src/Client/UI/{MenuActivator.ts → Components/MenuActivator.ts} +0 -0
- /package/src/Client/UI/{OfflineIndicator.ts → Components/OfflineIndicator.ts} +0 -0
- /package/src/Client/{Html → UI}/Context.ts +0 -0
|
@@ -37,24 +37,24 @@ export class ViewportScroller {
|
|
|
37
37
|
*/
|
|
38
38
|
get scrollOffset(): number {
|
|
39
39
|
if (this.#scrollOffset < 0) {
|
|
40
|
-
const fontSize = parseInt(getComputedStyle(document.body).fontSize);
|
|
40
|
+
const fontSize = Number.parseInt(getComputedStyle(document.body).fontSize);
|
|
41
41
|
this.#scrollOffset = Number.isNaN(fontSize) ? 0 : fontSize * 2;
|
|
42
42
|
|
|
43
|
-
const
|
|
44
|
-
this.#scrollOffset +=
|
|
43
|
+
const navbar = document.body.querySelector<HTMLElement>(".navbar");
|
|
44
|
+
this.#scrollOffset += (navbar?.offsetHeight ?? 0);
|
|
45
45
|
}
|
|
46
46
|
|
|
47
|
-
const actionBar = document.body.querySelector<HTMLElement>("action-bar");
|
|
47
|
+
const actionBar = document.body.querySelector<HTMLElement>("action-bar, .action-bar");
|
|
48
48
|
return this.#scrollOffset + (actionBar?.offsetHeight ?? 0);
|
|
49
49
|
}
|
|
50
50
|
|
|
51
51
|
/**
|
|
52
52
|
* Scrolls to the specified anchor.
|
|
53
|
-
* @param anchor The identifier or name of an
|
|
53
|
+
* @param anchor The identifier or name of an element.
|
|
54
54
|
* @param options Value indicating whether scrolling is instant or animates smoothly.
|
|
55
55
|
*/
|
|
56
56
|
scrollToAnchor(anchor: string, options: ScrollOptions = {}): void {
|
|
57
|
-
const element = document.getElementById(anchor) ??
|
|
57
|
+
const element = document.getElementById(anchor) ?? this.#viewport().querySelector(`[name="${anchor}"]`);
|
|
58
58
|
if (element) this.scrollToElement(element, options);
|
|
59
59
|
}
|
|
60
60
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"extends": "../../../tsconfig.json",
|
|
3
|
-
"include": ["
|
|
3
|
+
"include": ["**/*.ts"],
|
|
4
4
|
"compilerOptions": {
|
|
5
5
|
"composite": true,
|
|
6
6
|
"declaration": true,
|
|
@@ -9,9 +9,5 @@
|
|
|
9
9
|
"outDir": "../../../lib/UI",
|
|
10
10
|
"rootDir": ".",
|
|
11
11
|
"tsBuildInfoFile": "../../../var/UI.tsbuildinfo"
|
|
12
|
-
}
|
|
13
|
-
"references": [
|
|
14
|
-
{"path": "../Abstractions/tsconfig.json"},
|
|
15
|
-
{"path": "../Html/tsconfig.json"}
|
|
16
|
-
]
|
|
12
|
+
}
|
|
17
13
|
}
|
package/src/Client/tsconfig.json
CHANGED
|
@@ -1,12 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"files": [],
|
|
3
3
|
"references": [
|
|
4
|
-
{"path": "Abstractions/tsconfig.json"},
|
|
5
4
|
{"path": "Base/tsconfig.json"},
|
|
6
5
|
{"path": "Data/tsconfig.json"},
|
|
7
|
-
{"path": "
|
|
8
|
-
{"path": "
|
|
9
|
-
{"path": "Http/tsconfig.json"},
|
|
6
|
+
{"path": "Hosting/tsconfig.json"},
|
|
7
|
+
{"path": "Net/tsconfig.json"},
|
|
10
8
|
{"path": "UI/tsconfig.json"}
|
|
11
9
|
]
|
|
12
10
|
}
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* A component that shows up when an HTTP request starts, and hides when all concurrent HTTP requests are completed.
|
|
3
|
-
*/
|
|
4
|
-
export interface ILoadingIndicator {
|
|
5
|
-
/**
|
|
6
|
-
* Starts the loading indicator.
|
|
7
|
-
*/
|
|
8
|
-
start: () => void;
|
|
9
|
-
/**
|
|
10
|
-
* Stops the loading indicator.
|
|
11
|
-
* @param options Value indicating whether to force the loading indicator to stop.
|
|
12
|
-
*/
|
|
13
|
-
stop: (options?: {
|
|
14
|
-
force?: boolean;
|
|
15
|
-
}) => void;
|
|
16
|
-
}
|
|
17
|
-
//# sourceMappingURL=ILoadingIndicator.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ILoadingIndicator.d.ts","sourceRoot":"","sources":["../../src/Client/Abstractions/ILoadingIndicator.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAEjC;;OAEG;IACH,KAAK,EAAE,MAAM,IAAI,CAAC;IAElB;;;OAGG;IACH,IAAI,EAAE,CAAC,OAAO,CAAC,EAAE;QAAC,KAAK,CAAC,EAAE,OAAO,CAAA;KAAC,KAAK,IAAI,CAAC;CAC5C"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
package/lib/Date.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Date.d.ts","sourceRoot":"","sources":["../src/Client/Date.ts"],"names":[],"mappings":"AAEA;;;;GAIG;AACH,wBAAgB,UAAU,CAAC,IAAI,EAAE,IAAI,GAAG,IAAI,CAE3C;AAED;;;;GAIG;AACH,wBAAgB,WAAW,CAAC,IAAI,EAAE,IAAI,GAAG,MAAM,CAE9C;AAED;;;;GAIG;AACH,wBAAgB,SAAS,CAAC,IAAI,SAA2B,GAAG,IAAI,CAY/D;AAED;;;;GAIG;AACH,wBAAgB,WAAW,CAAC,IAAI,SAA2B,GAAG,IAAI,EAAE,CAoBnE;AAED;;;;GAIG;AACH,wBAAgB,UAAU,CAAC,IAAI,EAAE,IAAI,GAAG,MAAM,CAE7C;AAED;;;;GAIG;AACH,wBAAgB,aAAa,CAAC,IAAI,EAAE,IAAI,GAAG,MAAM,CAIhD;AAED;;;;GAIG;AACH,wBAAgB,UAAU,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO,CAG9C;AAED;;;;GAIG;AACH,wBAAgB,SAAS,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO,CAG7C;AAED;;;;GAIG;AACH,wBAAgB,YAAY,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO,CAGhD;AAED;;;;GAIG;AACH,wBAAgB,SAAS,CAAC,IAAI,EAAE,IAAI,GAAG,MAAM,CAE5C;AAED;;;;;GAKG;AACH,wBAAgB,QAAQ,CAAC,IAAI,EAAE,IAAI,EAAE,OAAO,GAAE;IAAC,WAAW,CAAC,EAAE,OAAO,CAAC;IAAC,WAAW,CAAC,EAAE,OAAO,CAAC;IAAC,SAAS,CAAC,EAAE,MAAM,CAAA;CAAM,GAAG,MAAM,CAM7H"}
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Provides a dependency container.
|
|
3
|
-
*/
|
|
4
|
-
export declare class Container {
|
|
5
|
-
#private;
|
|
6
|
-
/**
|
|
7
|
-
* Removes the service registered with the specified identifier.
|
|
8
|
-
* @param id The identification token.
|
|
9
|
-
*/
|
|
10
|
-
delete(id: ContainerToken): void;
|
|
11
|
-
/**
|
|
12
|
-
* Gets the service registered with the specified identifier.
|
|
13
|
-
* @param id The identification token.
|
|
14
|
-
* @returns The instance of the service registered with the specified identifier.
|
|
15
|
-
* @throws `Error` if there is no factory registered with the specified identifier.
|
|
16
|
-
*/
|
|
17
|
-
get<T>(id: ContainerToken): T;
|
|
18
|
-
/**
|
|
19
|
-
* Gets a value indicating whether this container has a service registered with the specified identifier.
|
|
20
|
-
* @param id The identification token.
|
|
21
|
-
* @returns `true` if a service registered with the specified identifier exists in this container, otherwise `false`.
|
|
22
|
-
*/
|
|
23
|
-
has(id: ContainerToken): boolean;
|
|
24
|
-
/**
|
|
25
|
-
* Registers a service factory with this container.
|
|
26
|
-
* @param id The identification token.
|
|
27
|
-
* @param factory The service factory.
|
|
28
|
-
* @returns This instance.
|
|
29
|
-
*/
|
|
30
|
-
register(id: ContainerToken, factory: () => unknown): this;
|
|
31
|
-
/**
|
|
32
|
-
* Registers a service instance with this container.
|
|
33
|
-
* @param id The identification token.
|
|
34
|
-
* @param service The service instance.
|
|
35
|
-
* @returns This instance.
|
|
36
|
-
*/
|
|
37
|
-
set(id: ContainerToken, service: unknown): this;
|
|
38
|
-
}
|
|
39
|
-
/**
|
|
40
|
-
* A token identifying a service.
|
|
41
|
-
*/
|
|
42
|
-
export type ContainerToken = string | symbol | (new (...args: any[]) => any);
|
|
43
|
-
//# sourceMappingURL=Container.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Container.d.ts","sourceRoot":"","sources":["../../src/Client/DependencyInjection/Container.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,qBAAa,SAAS;;IAYrB;;;OAGG;IACH,MAAM,CAAC,EAAE,EAAE,cAAc,GAAG,IAAI;IAKhC;;;;;OAKG;IACH,GAAG,CAAC,CAAC,EAAE,EAAE,EAAE,cAAc,GAAG,CAAC;IAS7B;;;;OAIG;IACH,GAAG,CAAC,EAAE,EAAE,cAAc,GAAG,OAAO;IAIhC;;;;;OAKG;IACH,QAAQ,CAAC,EAAE,EAAE,cAAc,EAAE,OAAO,EAAE,MAAM,OAAO,GAAG,IAAI;IAK1D;;;;;OAKG;IACH,GAAG,CAAC,EAAE,EAAE,cAAc,EAAE,OAAO,EAAE,OAAO,GAAG,IAAI;CAI/C;AAED;;GAEG;AACH,MAAM,MAAM,cAAc,GAAG,MAAM,GAAC,MAAM,GAAC,CAAC,KAAI,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,GAAG,CAAC,CAAC"}
|
|
@@ -1,65 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Provides a dependency container.
|
|
3
|
-
*/
|
|
4
|
-
export class Container {
|
|
5
|
-
/**
|
|
6
|
-
* The registered factories.
|
|
7
|
-
*/
|
|
8
|
-
#factories = new Map;
|
|
9
|
-
/**
|
|
10
|
-
* The registered services.
|
|
11
|
-
*/
|
|
12
|
-
#services = new Map;
|
|
13
|
-
/**
|
|
14
|
-
* Removes the service registered with the specified identifier.
|
|
15
|
-
* @param id The identification token.
|
|
16
|
-
*/
|
|
17
|
-
delete(id) {
|
|
18
|
-
this.#factories.delete(id);
|
|
19
|
-
this.#services.delete(id);
|
|
20
|
-
}
|
|
21
|
-
/**
|
|
22
|
-
* Gets the service registered with the specified identifier.
|
|
23
|
-
* @param id The identification token.
|
|
24
|
-
* @returns The instance of the service registered with the specified identifier.
|
|
25
|
-
* @throws `Error` if there is no factory registered with the specified identifier.
|
|
26
|
-
*/
|
|
27
|
-
get(id) {
|
|
28
|
-
if (!this.#services.has(id))
|
|
29
|
-
if (this.#factories.has(id))
|
|
30
|
-
this.set(id, this.#factories.get(id).call(this));
|
|
31
|
-
else if (typeof id == "function")
|
|
32
|
-
this.set(id, Reflect.construct(id, []));
|
|
33
|
-
else
|
|
34
|
-
throw Error("There is no factory registered with the specified identifier.");
|
|
35
|
-
return this.#services.get(id);
|
|
36
|
-
}
|
|
37
|
-
/**
|
|
38
|
-
* Gets a value indicating whether this container has a service registered with the specified identifier.
|
|
39
|
-
* @param id The identification token.
|
|
40
|
-
* @returns `true` if a service registered with the specified identifier exists in this container, otherwise `false`.
|
|
41
|
-
*/
|
|
42
|
-
has(id) {
|
|
43
|
-
return this.#factories.has(id) || this.#services.has(id);
|
|
44
|
-
}
|
|
45
|
-
/**
|
|
46
|
-
* Registers a service factory with this container.
|
|
47
|
-
* @param id The identification token.
|
|
48
|
-
* @param factory The service factory.
|
|
49
|
-
* @returns This instance.
|
|
50
|
-
*/
|
|
51
|
-
register(id, factory) {
|
|
52
|
-
this.#factories.set(id, factory);
|
|
53
|
-
return this;
|
|
54
|
-
}
|
|
55
|
-
/**
|
|
56
|
-
* Registers a service instance with this container.
|
|
57
|
-
* @param id The identification token.
|
|
58
|
-
* @param service The service instance.
|
|
59
|
-
* @returns This instance.
|
|
60
|
-
*/
|
|
61
|
-
set(id, service) {
|
|
62
|
-
this.#services.set(id, service);
|
|
63
|
-
return this;
|
|
64
|
-
}
|
|
65
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"AppTheme.d.ts","sourceRoot":"","sources":["../../src/Client/Html/AppTheme.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,eAAO,MAAM,QAAQ;IAEpB;;OAEG;;IAGH;;OAEG;;IAGH;;OAEG;;EAEF,CAAC;AAEH;;GAEG;AACH,MAAM,MAAM,QAAQ,GAAG,OAAO,QAAQ,CAAC,MAAM,OAAO,QAAQ,CAAC,CAAC;AAE9D;;;;GAIG;AACH,wBAAgB,OAAO,CAAC,KAAK,EAAE,QAAQ,GAAG,MAAM,CAM/C;AAED;;;;GAIG;AACH,wBAAgB,QAAQ,CAAC,KAAK,EAAE,QAAQ,GAAG,MAAM,CAMhD"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Context.d.ts","sourceRoot":"","sources":["../../src/Client/Html/Context.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,eAAO,MAAM,OAAO;IAEnB;;OAEG;;IAGH;;OAEG;;IAGH;;OAEG;;IAGH;;OAEG;;EAEF,CAAC;AAEH;;GAEG;AACH,MAAM,MAAM,OAAO,GAAG,OAAO,OAAO,CAAC,MAAM,OAAO,OAAO,CAAC,CAAC;AAE3D;;;;GAIG;AACH,wBAAgB,OAAO,CAAC,OAAO,EAAE,OAAO,GAAG,MAAM,CAOhD"}
|
package/lib/Html/File.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"File.d.ts","sourceRoot":"","sources":["../../src/Client/Html/File.ts"],"names":[],"mappings":"AAEA;;;GAGG;AACH,wBAAgB,YAAY,CAAC,IAAI,EAAE,IAAI,GAAG,IAAI,CAU7C;AAED;;;;;GAKG;AACH,wBAAgB,cAAc,CAAC,IAAI,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,EAAE,OAAO,GAAE,eAAoB,GAAG,IAAI,CAElG;AAED;;;;GAIG;AACH,wBAAgB,QAAQ,CAAC,IAAI,EAAE,IAAI,EAAE,OAAO,GAAE;IAAC,MAAM,CAAC,EAAE,OAAO,CAAA;CAAM,GAAG,IAAI,CAkB3E;AAED;;;GAGG;AACH,wBAAgB,SAAS,CAAC,IAAI,EAAE,IAAI,GAAG,IAAI,CAa1C;AAED;;;;GAIG;AACH,wBAAgB,SAAS,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO,CAAC,GAAG,CAAC,CAOlD"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ViewportScroller.d.ts","sourceRoot":"","sources":["../../src/Client/Html/ViewportScroller.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,MAAM,MAAM,aAAa,GAAG,OAAO,CAAC;IAEnC;;OAEG;IACH,QAAQ,EAAE,cAAc,CAAA;CACxB,CAAC,CAAC;AAEH;;GAEG;AACH,qBAAa,gBAAgB;;IAY5B;;;OAGG;gBACS,QAAQ,GAAE,MAAM,OAAqE;IAIjG;;OAEG;IACH,IAAI,YAAY,IAAI,MAAM,CAWzB;IAED;;;;OAIG;IACH,cAAc,CAAC,MAAM,EAAE,MAAM,EAAE,OAAO,GAAE,aAAkB,GAAG,IAAI;IAKjE;;;;OAIG;IACH,eAAe,CAAC,OAAO,EAAE,OAAO,EAAE,OAAO,GAAE,aAAkB,GAAG,IAAI;IAMpE;;;;;OAKG;IACH,gBAAgB,CAAC,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,MAAM,EAAE,OAAO,GAAE,aAAkB,GAAG,IAAI;IAIzE;;;OAGG;IACH,WAAW,CAAC,OAAO,GAAE,aAAkB,GAAG,IAAI;CAG9C"}
|
package/lib/Http/HttpClient.d.ts
DELETED
|
@@ -1,68 +0,0 @@
|
|
|
1
|
-
import type { ILoadingIndicator } from "#Abstractions/ILoadingIndicator.js";
|
|
2
|
-
/**
|
|
3
|
-
* Performs HTTP requests.
|
|
4
|
-
*/
|
|
5
|
-
export declare class HttpClient {
|
|
6
|
-
#private;
|
|
7
|
-
/**
|
|
8
|
-
* The base URL of the remote service.
|
|
9
|
-
*/
|
|
10
|
-
readonly baseUrl: URL;
|
|
11
|
-
/**
|
|
12
|
-
* Creates a new HTTP client.
|
|
13
|
-
* @param options An object providing values to initialize this instance.
|
|
14
|
-
*/
|
|
15
|
-
constructor(options?: HttpClientOptions);
|
|
16
|
-
/**
|
|
17
|
-
* Performs a DELETE request.
|
|
18
|
-
* @param url The URL of the resource to fetch.
|
|
19
|
-
* @param options The request options.
|
|
20
|
-
* @returns The server response.
|
|
21
|
-
*/
|
|
22
|
-
delete(url?: string | URL, options?: RequestInit): Promise<Response>;
|
|
23
|
-
/**
|
|
24
|
-
* Performs a GET request.
|
|
25
|
-
* @param url The URL of the resource to fetch.
|
|
26
|
-
* @param options The request options.
|
|
27
|
-
* @returns The server response.
|
|
28
|
-
*/
|
|
29
|
-
get(url?: string | URL, options?: RequestInit): Promise<Response>;
|
|
30
|
-
/**
|
|
31
|
-
* Performs a PATCH request.
|
|
32
|
-
* @param url The URL of the resource to fetch.
|
|
33
|
-
* @param body The request body.
|
|
34
|
-
* @param options The request options.
|
|
35
|
-
* @returns The server response.
|
|
36
|
-
*/
|
|
37
|
-
patch(url?: string | URL, body?: unknown, options?: RequestInit): Promise<Response>;
|
|
38
|
-
/**
|
|
39
|
-
* Performs a POST request.
|
|
40
|
-
* @param url The URL of the resource to fetch.
|
|
41
|
-
* @param body The request body.
|
|
42
|
-
* @param options The request options.
|
|
43
|
-
* @returns The server response.
|
|
44
|
-
*/
|
|
45
|
-
post(url?: string | URL, body?: unknown, options?: RequestInit): Promise<Response>;
|
|
46
|
-
/**
|
|
47
|
-
* Performs a PUT request.
|
|
48
|
-
* @param url The URL of the resource to fetch.
|
|
49
|
-
* @param body The request body.
|
|
50
|
-
* @param options The request options.
|
|
51
|
-
* @returns The server response.
|
|
52
|
-
*/
|
|
53
|
-
put(url?: string | URL, body?: unknown, options?: RequestInit): Promise<Response>;
|
|
54
|
-
}
|
|
55
|
-
/**
|
|
56
|
-
* Defines the options of a {@link HttpClient} instance.
|
|
57
|
-
*/
|
|
58
|
-
export type HttpClientOptions = Partial<{
|
|
59
|
-
/**
|
|
60
|
-
* The base URL of the remote service.
|
|
61
|
-
*/
|
|
62
|
-
baseUrl: string | URL;
|
|
63
|
-
/**
|
|
64
|
-
* The function returning the component used as loading indicator.
|
|
65
|
-
*/
|
|
66
|
-
loadingIndicator: () => ILoadingIndicator | null;
|
|
67
|
-
}>;
|
|
68
|
-
//# sourceMappingURL=HttpClient.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"HttpClient.d.ts","sourceRoot":"","sources":["../../src/Client/Http/HttpClient.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAC,iBAAiB,EAAC,MAAM,oCAAoC,CAAC;AAG1E;;GAEG;AACH,qBAAa,UAAU;;IAEtB;;OAEG;IACH,QAAQ,CAAC,OAAO,EAAE,GAAG,CAAC;IAOtB;;;OAGG;gBACS,OAAO,GAAE,iBAAsB;IAM3C;;;;;OAKG;IACH,MAAM,CAAC,GAAG,CAAC,EAAE,MAAM,GAAC,GAAG,EAAE,OAAO,CAAC,EAAE,WAAW,GAAG,OAAO,CAAC,QAAQ,CAAC;IAIlE;;;;;OAKG;IACH,GAAG,CAAC,GAAG,CAAC,EAAE,MAAM,GAAC,GAAG,EAAE,OAAO,CAAC,EAAE,WAAW,GAAG,OAAO,CAAC,QAAQ,CAAC;IAI/D;;;;;;OAMG;IACH,KAAK,CAAC,GAAG,CAAC,EAAE,MAAM,GAAC,GAAG,EAAE,IAAI,CAAC,EAAE,OAAO,EAAE,OAAO,CAAC,EAAE,WAAW,GAAG,OAAO,CAAC,QAAQ,CAAC;IAIjF;;;;;;OAMG;IACH,IAAI,CAAC,GAAG,CAAC,EAAE,MAAM,GAAC,GAAG,EAAE,IAAI,CAAC,EAAE,OAAO,EAAE,OAAO,CAAC,EAAE,WAAW,GAAG,OAAO,CAAC,QAAQ,CAAC;IAIhF;;;;;;OAMG;IACH,GAAG,CAAC,GAAG,CAAC,EAAE,MAAM,GAAC,GAAG,EAAE,IAAI,CAAC,EAAE,OAAO,EAAE,OAAO,CAAC,EAAE,WAAW,GAAG,OAAO,CAAC,QAAQ,CAAC;CAiC/E;AAED;;GAEG;AACH,MAAM,MAAM,iBAAiB,GAAG,OAAO,CAAC;IAEvC;;OAEG;IACH,OAAO,EAAE,MAAM,GAAC,GAAG,CAAC;IAEpB;;OAEG;IACH,gBAAgB,EAAE,MAAM,iBAAiB,GAAC,IAAI,CAAC;CAC/C,CAAC,CAAC"}
|
package/lib/Http/HttpClient.js
DELETED
|
@@ -1,102 +0,0 @@
|
|
|
1
|
-
import { HttpError } from "./HttpError.js";
|
|
2
|
-
/**
|
|
3
|
-
* Performs HTTP requests.
|
|
4
|
-
*/
|
|
5
|
-
export class HttpClient {
|
|
6
|
-
/**
|
|
7
|
-
* The base URL of the remote service.
|
|
8
|
-
*/
|
|
9
|
-
baseUrl;
|
|
10
|
-
/**
|
|
11
|
-
* The function returning the component used as loading indicator.
|
|
12
|
-
*/
|
|
13
|
-
#loadingIndicator;
|
|
14
|
-
/**
|
|
15
|
-
* Creates a new HTTP client.
|
|
16
|
-
* @param options An object providing values to initialize this instance.
|
|
17
|
-
*/
|
|
18
|
-
constructor(options = {}) {
|
|
19
|
-
const url = options.baseUrl ? (options.baseUrl instanceof URL ? options.baseUrl.href : options.baseUrl) : document.baseURI;
|
|
20
|
-
this.baseUrl = new URL(url.endsWith("/") ? url : `${url}/`);
|
|
21
|
-
this.#loadingIndicator = options.loadingIndicator ?? (() => document.body.querySelector("loading-indicator"));
|
|
22
|
-
}
|
|
23
|
-
/**
|
|
24
|
-
* Performs a DELETE request.
|
|
25
|
-
* @param url The URL of the resource to fetch.
|
|
26
|
-
* @param options The request options.
|
|
27
|
-
* @returns The server response.
|
|
28
|
-
*/
|
|
29
|
-
delete(url, options) {
|
|
30
|
-
return this.#fetch("DELETE", url, null, options);
|
|
31
|
-
}
|
|
32
|
-
/**
|
|
33
|
-
* Performs a GET request.
|
|
34
|
-
* @param url The URL of the resource to fetch.
|
|
35
|
-
* @param options The request options.
|
|
36
|
-
* @returns The server response.
|
|
37
|
-
*/
|
|
38
|
-
get(url, options) {
|
|
39
|
-
return this.#fetch("GET", url, null, options);
|
|
40
|
-
}
|
|
41
|
-
/**
|
|
42
|
-
* Performs a PATCH request.
|
|
43
|
-
* @param url The URL of the resource to fetch.
|
|
44
|
-
* @param body The request body.
|
|
45
|
-
* @param options The request options.
|
|
46
|
-
* @returns The server response.
|
|
47
|
-
*/
|
|
48
|
-
patch(url, body, options) {
|
|
49
|
-
return this.#fetch("PATCH", url, body, options);
|
|
50
|
-
}
|
|
51
|
-
/**
|
|
52
|
-
* Performs a POST request.
|
|
53
|
-
* @param url The URL of the resource to fetch.
|
|
54
|
-
* @param body The request body.
|
|
55
|
-
* @param options The request options.
|
|
56
|
-
* @returns The server response.
|
|
57
|
-
*/
|
|
58
|
-
post(url, body, options) {
|
|
59
|
-
return this.#fetch("POST", url, body, options);
|
|
60
|
-
}
|
|
61
|
-
/**
|
|
62
|
-
* Performs a PUT request.
|
|
63
|
-
* @param url The URL of the resource to fetch.
|
|
64
|
-
* @param body The request body.
|
|
65
|
-
* @param options The request options.
|
|
66
|
-
* @returns The server response.
|
|
67
|
-
*/
|
|
68
|
-
put(url, body, options) {
|
|
69
|
-
return this.#fetch("PUT", url, body, options);
|
|
70
|
-
}
|
|
71
|
-
/**
|
|
72
|
-
* Performs a custom HTTP request.
|
|
73
|
-
* @param method The HTTP method.
|
|
74
|
-
* @param url The URL of the resource to fetch.
|
|
75
|
-
* @param body The request body.
|
|
76
|
-
* @param options The request options.
|
|
77
|
-
* @returns The server response.
|
|
78
|
-
*/
|
|
79
|
-
async #fetch(method, url = "", body = null, options = {}) {
|
|
80
|
-
const headers = new Headers(options.headers);
|
|
81
|
-
if (!headers.has("accept"))
|
|
82
|
-
headers.set("accept", "application/json");
|
|
83
|
-
if (body && !(body instanceof Blob || body instanceof FormData || body instanceof URLSearchParams)) {
|
|
84
|
-
if (typeof body != "string")
|
|
85
|
-
body = JSON.stringify(body);
|
|
86
|
-
if (!headers.has("content-type"))
|
|
87
|
-
headers.set("content-type", "application/json");
|
|
88
|
-
}
|
|
89
|
-
const loadingIndicator = this.#loadingIndicator();
|
|
90
|
-
try {
|
|
91
|
-
loadingIndicator?.start();
|
|
92
|
-
const request = new Request(new URL(url, this.baseUrl), { ...options, method, headers, body });
|
|
93
|
-
const response = await fetch(request);
|
|
94
|
-
if (!response.ok)
|
|
95
|
-
throw new HttpError(response);
|
|
96
|
-
return response;
|
|
97
|
-
}
|
|
98
|
-
finally {
|
|
99
|
-
loadingIndicator?.stop();
|
|
100
|
-
}
|
|
101
|
-
}
|
|
102
|
-
}
|
package/lib/Http/HttpError.d.ts
DELETED
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
import { StatusCodes } from "./StatusCodes.js";
|
|
2
|
-
/**
|
|
3
|
-
* An object thrown when an HTTP error occurs.
|
|
4
|
-
*/
|
|
5
|
-
export declare class HttpError extends globalThis.Error {
|
|
6
|
-
#private;
|
|
7
|
-
/**
|
|
8
|
-
* Creates a new HTTP error.
|
|
9
|
-
* @param response The server response.
|
|
10
|
-
*/
|
|
11
|
-
constructor(response: Response);
|
|
12
|
-
/**
|
|
13
|
-
* The server response.
|
|
14
|
-
*/
|
|
15
|
-
get cause(): Response;
|
|
16
|
-
/**
|
|
17
|
-
* Value indicating whether the response's status code is between 400 and 499.
|
|
18
|
-
*/
|
|
19
|
-
get isClientError(): boolean;
|
|
20
|
-
/**
|
|
21
|
-
* Value indicating whether the response's status code is between 500 and 599.
|
|
22
|
-
*/
|
|
23
|
-
get isServerError(): boolean;
|
|
24
|
-
/**
|
|
25
|
-
* The response's status code.
|
|
26
|
-
*/
|
|
27
|
-
get status(): StatusCodes;
|
|
28
|
-
/**
|
|
29
|
-
* The validation errors.
|
|
30
|
-
*/
|
|
31
|
-
get validationErrors(): Promise<Map<string, string>>;
|
|
32
|
-
}
|
|
33
|
-
//# sourceMappingURL=HttpError.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"HttpError.d.ts","sourceRoot":"","sources":["../../src/Client/Http/HttpError.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,WAAW,EAAC,MAAM,kBAAkB,CAAC;AAE7C;;GAEG;AACH,qBAAa,SAAU,SAAQ,UAAU,CAAC,KAAK;;IAO9C;;;OAGG;gBACS,QAAQ,EAAE,QAAQ;IAK9B;;OAEG;IACH,IAAa,KAAK,IAAI,QAAQ,CAE7B;IAED;;OAEG;IACH,IAAI,aAAa,IAAI,OAAO,CAG3B;IAED;;OAEG;IACH,IAAI,aAAa,IAAI,OAAO,CAG3B;IAED;;OAEG;IACH,IAAI,MAAM,IAAI,WAAW,CAExB;IAED;;OAEG;IACH,IAAI,gBAAgB,IAAI,OAAO,CAAC,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,CAInD;CAgBD"}
|
package/lib/Http/HttpError.js
DELETED
|
@@ -1,66 +0,0 @@
|
|
|
1
|
-
import { StatusCodes } from "./StatusCodes.js";
|
|
2
|
-
/**
|
|
3
|
-
* An object thrown when an HTTP error occurs.
|
|
4
|
-
*/
|
|
5
|
-
export class HttpError extends globalThis.Error {
|
|
6
|
-
/**
|
|
7
|
-
* The validation errors.
|
|
8
|
-
*/
|
|
9
|
-
#validationErrors = null;
|
|
10
|
-
/**
|
|
11
|
-
* Creates a new HTTP error.
|
|
12
|
-
* @param response The server response.
|
|
13
|
-
*/
|
|
14
|
-
constructor(response) {
|
|
15
|
-
super(`${response.status} ${response.statusText}`, { cause: response });
|
|
16
|
-
this.name = "HttpError";
|
|
17
|
-
}
|
|
18
|
-
/**
|
|
19
|
-
* The server response.
|
|
20
|
-
*/
|
|
21
|
-
get cause() {
|
|
22
|
-
return super.cause;
|
|
23
|
-
}
|
|
24
|
-
/**
|
|
25
|
-
* Value indicating whether the response's status code is between 400 and 499.
|
|
26
|
-
*/
|
|
27
|
-
get isClientError() {
|
|
28
|
-
const { status } = this;
|
|
29
|
-
return status >= 400 && status < 500;
|
|
30
|
-
}
|
|
31
|
-
/**
|
|
32
|
-
* Value indicating whether the response's status code is between 500 and 599.
|
|
33
|
-
*/
|
|
34
|
-
get isServerError() {
|
|
35
|
-
const { status } = this;
|
|
36
|
-
return status >= 500 && status < 600;
|
|
37
|
-
}
|
|
38
|
-
/**
|
|
39
|
-
* The response's status code.
|
|
40
|
-
*/
|
|
41
|
-
get status() {
|
|
42
|
-
return this.cause.status;
|
|
43
|
-
}
|
|
44
|
-
/**
|
|
45
|
-
* The validation errors.
|
|
46
|
-
*/
|
|
47
|
-
get validationErrors() {
|
|
48
|
-
return this.#validationErrors
|
|
49
|
-
? Promise.resolve(this.#validationErrors)
|
|
50
|
-
: this.#parseValidationErrors().then(errors => this.#validationErrors = errors);
|
|
51
|
-
}
|
|
52
|
-
/**
|
|
53
|
-
* Parses the validation errors returned in the body of the specified response.
|
|
54
|
-
* @returns The validation errors provided by the response body.
|
|
55
|
-
*/
|
|
56
|
-
async #parseValidationErrors() {
|
|
57
|
-
try {
|
|
58
|
-
const statuses = new Set([StatusCodes.BadRequest, StatusCodes.UnprocessableContent]);
|
|
59
|
-
const ignoreBody = this.cause.bodyUsed || !statuses.has(this.status);
|
|
60
|
-
return new Map(ignoreBody ? [] : Object.entries(await this.cause.json()));
|
|
61
|
-
}
|
|
62
|
-
catch {
|
|
63
|
-
return new Map;
|
|
64
|
-
}
|
|
65
|
-
}
|
|
66
|
-
}
|
|
@@ -1,114 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Provides common HTTP status codes.
|
|
3
|
-
*/
|
|
4
|
-
export declare const StatusCodes: Readonly<{
|
|
5
|
-
/**
|
|
6
|
-
* The `OK` status.
|
|
7
|
-
*/
|
|
8
|
-
OK: 200;
|
|
9
|
-
/**
|
|
10
|
-
* The `Created` status.
|
|
11
|
-
*/
|
|
12
|
-
Created: 201;
|
|
13
|
-
/**
|
|
14
|
-
* The `No Content` status.
|
|
15
|
-
*/
|
|
16
|
-
NoContent: 204;
|
|
17
|
-
/**
|
|
18
|
-
* The `Moved Permanently` status.
|
|
19
|
-
*/
|
|
20
|
-
MovedPermanently: 301;
|
|
21
|
-
/**
|
|
22
|
-
* The `Found` status.
|
|
23
|
-
*/
|
|
24
|
-
Found: 302;
|
|
25
|
-
/**
|
|
26
|
-
* The `Not Modified` status.
|
|
27
|
-
*/
|
|
28
|
-
NotModified: 304;
|
|
29
|
-
/**
|
|
30
|
-
* The `Bad Request` status.
|
|
31
|
-
*/
|
|
32
|
-
BadRequest: 400;
|
|
33
|
-
/**
|
|
34
|
-
* The `Unauthorized` status.
|
|
35
|
-
*/
|
|
36
|
-
Unauthorized: 401;
|
|
37
|
-
/**
|
|
38
|
-
* The `Payment Required` status.
|
|
39
|
-
*/
|
|
40
|
-
PaymentRequired: 402;
|
|
41
|
-
/**
|
|
42
|
-
* The `Forbidden` status.
|
|
43
|
-
*/
|
|
44
|
-
Forbidden: 403;
|
|
45
|
-
/**
|
|
46
|
-
* The `Not Found` status.
|
|
47
|
-
*/
|
|
48
|
-
NotFound: 404;
|
|
49
|
-
/**
|
|
50
|
-
* The `Method Not Allowed` status.
|
|
51
|
-
*/
|
|
52
|
-
MethodNotAllowed: 405;
|
|
53
|
-
/**
|
|
54
|
-
* The `Not Acceptable` status.
|
|
55
|
-
*/
|
|
56
|
-
NotAcceptable: 406;
|
|
57
|
-
/**
|
|
58
|
-
* The `Request Timeout` status.
|
|
59
|
-
*/
|
|
60
|
-
RequestTimeout: 408;
|
|
61
|
-
/**
|
|
62
|
-
* The `Conflict` status.
|
|
63
|
-
*/
|
|
64
|
-
Conflict: 409;
|
|
65
|
-
/**
|
|
66
|
-
* The `Payload Too Large` status.
|
|
67
|
-
*/
|
|
68
|
-
PayloadTooLarge: 413;
|
|
69
|
-
/**
|
|
70
|
-
* The `Unsupported Media Type` status.
|
|
71
|
-
*/
|
|
72
|
-
UnsupportedMediaType: 415;
|
|
73
|
-
/**
|
|
74
|
-
* The `Page Expired` status.
|
|
75
|
-
*/
|
|
76
|
-
PageExpired: 419;
|
|
77
|
-
/**
|
|
78
|
-
* The `Unprocessable Content` status.
|
|
79
|
-
*/
|
|
80
|
-
UnprocessableContent: 422;
|
|
81
|
-
/**
|
|
82
|
-
* The `Too Many Requests` status.
|
|
83
|
-
*/
|
|
84
|
-
TooManyRequests: 429;
|
|
85
|
-
/**
|
|
86
|
-
* The `Internal Server Error` status.
|
|
87
|
-
*/
|
|
88
|
-
InternalServerError: 500;
|
|
89
|
-
/**
|
|
90
|
-
* The `Not Implemented` status.
|
|
91
|
-
*/
|
|
92
|
-
NotImplemented: 501;
|
|
93
|
-
/**
|
|
94
|
-
* The `Bad Gateway` status.
|
|
95
|
-
*/
|
|
96
|
-
BadGateway: 502;
|
|
97
|
-
/**
|
|
98
|
-
* The `Service Unavailable` status.
|
|
99
|
-
*/
|
|
100
|
-
ServiceUnavailable: 503;
|
|
101
|
-
/**
|
|
102
|
-
* The `Gateway Timeout` status.
|
|
103
|
-
*/
|
|
104
|
-
GatewayTimeout: 504;
|
|
105
|
-
/**
|
|
106
|
-
* The `Bandwidth Limit Exceeded` status
|
|
107
|
-
*/
|
|
108
|
-
BandwidthLimitExceeded: 509;
|
|
109
|
-
}>;
|
|
110
|
-
/**
|
|
111
|
-
* Provides common HTTP status codes.
|
|
112
|
-
*/
|
|
113
|
-
export type StatusCodes = typeof StatusCodes[keyof typeof StatusCodes];
|
|
114
|
-
//# sourceMappingURL=StatusCodes.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"StatusCodes.d.ts","sourceRoot":"","sources":["../../src/Client/Http/StatusCodes.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,eAAO,MAAM,WAAW;IAEvB;;OAEG;;IAGH;;OAEG;;IAGH;;OAEG;;IAGH;;OAEG;;IAGH;;OAEG;;IAGH;;OAEG;;IAGH;;OAEG;;IAGH;;OAEG;;IAGH;;OAEG;;IAGH;;OAEG;;IAGH;;OAEG;;IAGH;;OAEG;;IAGH;;OAEG;;IAGH;;OAEG;;IAGH;;OAEG;;IAGH;;OAEG;;IAGH;;OAEG;;IAGH;;OAEG;;IAGH;;OAEG;;IAGH;;OAEG;;IAGH;;OAEG;;IAGH;;OAEG;;IAGH;;OAEG;;IAGH;;OAEG;;IAGH;;OAEG;;IAGH;;OAEG;;EAEF,CAAC;AAEH;;GAEG;AACH,MAAM,MAAM,WAAW,GAAG,OAAO,WAAW,CAAC,MAAM,OAAO,WAAW,CAAC,CAAC"}
|