@xh/hoist 70.0.0-SNAPSHOT.1729789044498 → 70.0.0-SNAPSHOT.1731001551514
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/CHANGELOG.md +5 -0
- package/build/types/core/exception/Exception.d.ts +1 -3
- package/build/types/desktop/cmp/appOption/AutoRefreshAppOption.d.ts +3 -3
- package/build/types/desktop/cmp/appOption/ThemeAppOption.d.ts +3 -3
- package/core/exception/Exception.ts +11 -7
- package/package.json +4 -4
- package/svc/FetchService.ts +2 -1
- package/tsconfig.tsbuildinfo +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -5,10 +5,15 @@
|
|
|
5
5
|
### ⚙️ Technical
|
|
6
6
|
|
|
7
7
|
* Deprecated `FileChooserModel.removeAllFiles()`, replaced with `clear()` for brevity/consistency.
|
|
8
|
+
* Improved timeout error message thrown by `FetchService` to format the timeout interval in seconds
|
|
9
|
+
where possible.
|
|
8
10
|
|
|
9
11
|
### 📚 Libraries
|
|
10
12
|
|
|
13
|
+
* @azure/msal-browser `3.23 → 3.27`
|
|
11
14
|
* @fortawesome/fontawesome-pro `6.2 → 6.6`
|
|
15
|
+
* qs `6.12 → 6.13`
|
|
16
|
+
* store2 `2.13 → 2.14`
|
|
12
17
|
|
|
13
18
|
## 69.0.0 - 2024-10-17
|
|
14
19
|
|
|
@@ -18,9 +18,7 @@ export declare class Exception {
|
|
|
18
18
|
* Other inputs will be treated as the `message` of a new HoistException.
|
|
19
19
|
*/
|
|
20
20
|
static create(src: unknown): HoistException;
|
|
21
|
-
/**
|
|
22
|
-
* Create an Error for when an operation (e.g. a Promise) times out.
|
|
23
|
-
*/
|
|
21
|
+
/** Create an Error for when an operation (e.g. a Promise) times out. */
|
|
24
22
|
static timeout(config: TimeoutExceptionConfig): TimeoutException;
|
|
25
23
|
/**
|
|
26
24
|
* Create an Error to throw when a fetch call returns a !ok response.
|
|
@@ -83,6 +83,7 @@ export declare const autoRefreshAppOption: ({ formFieldProps, inputProps }?: Aut
|
|
|
83
83
|
suppressContentEditableWarning?: boolean;
|
|
84
84
|
suppressHydrationWarning?: boolean;
|
|
85
85
|
accessKey?: string;
|
|
86
|
+
autoCapitalize?: "off" | "none" | "on" | "sentences" | "words" | "characters" | (string & {});
|
|
86
87
|
autoFocus?: boolean;
|
|
87
88
|
contentEditable?: "inherit" | (boolean | "true" | "false") | "plaintext-only";
|
|
88
89
|
dir?: string;
|
|
@@ -106,7 +107,6 @@ export declare const autoRefreshAppOption: ({ formFieldProps, inputProps }?: Aut
|
|
|
106
107
|
rev?: string;
|
|
107
108
|
typeof?: string;
|
|
108
109
|
vocab?: string;
|
|
109
|
-
autoCapitalize?: string;
|
|
110
110
|
autoCorrect?: string;
|
|
111
111
|
autoSave?: string;
|
|
112
112
|
color?: string;
|
|
@@ -117,12 +117,12 @@ export declare const autoRefreshAppOption: ({ formFieldProps, inputProps }?: Aut
|
|
|
117
117
|
itemRef?: string;
|
|
118
118
|
results?: number;
|
|
119
119
|
security?: string;
|
|
120
|
-
unselectable?: "
|
|
120
|
+
unselectable?: "off" | "on";
|
|
121
121
|
inputMode?: "search" | "text" | "none" | "tel" | "url" | "email" | "numeric" | "decimal";
|
|
122
122
|
is?: string;
|
|
123
123
|
"aria-activedescendant"?: string;
|
|
124
124
|
"aria-atomic"?: boolean | "true" | "false";
|
|
125
|
-
"aria-autocomplete"?: "
|
|
125
|
+
"aria-autocomplete"?: "none" | "list" | "inline" | "both";
|
|
126
126
|
"aria-braillelabel"?: string;
|
|
127
127
|
"aria-brailleroledescription"?: string;
|
|
128
128
|
"aria-busy"?: boolean | "true" | "false";
|
|
@@ -81,6 +81,7 @@ export declare const themeAppOption: ({ formFieldProps, inputProps }?: ThemeAppO
|
|
|
81
81
|
suppressContentEditableWarning?: boolean;
|
|
82
82
|
suppressHydrationWarning?: boolean;
|
|
83
83
|
accessKey?: string;
|
|
84
|
+
autoCapitalize?: "off" | "none" | "on" | "sentences" | "words" | "characters" | (string & {});
|
|
84
85
|
autoFocus?: boolean;
|
|
85
86
|
contentEditable?: "inherit" | (boolean | "true" | "false") | "plaintext-only";
|
|
86
87
|
dir?: string;
|
|
@@ -104,7 +105,6 @@ export declare const themeAppOption: ({ formFieldProps, inputProps }?: ThemeAppO
|
|
|
104
105
|
rev?: string;
|
|
105
106
|
typeof?: string;
|
|
106
107
|
vocab?: string;
|
|
107
|
-
autoCapitalize?: string;
|
|
108
108
|
autoCorrect?: string;
|
|
109
109
|
autoSave?: string;
|
|
110
110
|
color?: string;
|
|
@@ -115,12 +115,12 @@ export declare const themeAppOption: ({ formFieldProps, inputProps }?: ThemeAppO
|
|
|
115
115
|
itemRef?: string;
|
|
116
116
|
results?: number;
|
|
117
117
|
security?: string;
|
|
118
|
-
unselectable?: "
|
|
118
|
+
unselectable?: "off" | "on";
|
|
119
119
|
inputMode?: "search" | "text" | "none" | "tel" | "url" | "email" | "numeric" | "decimal";
|
|
120
120
|
is?: string;
|
|
121
121
|
"aria-activedescendant"?: string;
|
|
122
122
|
"aria-atomic"?: boolean | "true" | "false";
|
|
123
|
-
"aria-autocomplete"?: "
|
|
123
|
+
"aria-autocomplete"?: "none" | "list" | "inline" | "both";
|
|
124
124
|
"aria-braillelabel"?: string;
|
|
125
125
|
"aria-brailleroledescription"?: string;
|
|
126
126
|
"aria-busy"?: boolean | "true" | "false";
|
|
@@ -4,10 +4,10 @@
|
|
|
4
4
|
*
|
|
5
5
|
* Copyright © 2024 Extremely Heavy Industries Inc.
|
|
6
6
|
*/
|
|
7
|
+
import {PlainObject, XH} from '@xh/hoist/core';
|
|
7
8
|
import {FetchOptions} from '@xh/hoist/svc';
|
|
8
|
-
import {
|
|
9
|
+
import {pluralize} from '@xh/hoist/utils/js';
|
|
9
10
|
import {isPlainObject} from 'lodash';
|
|
10
|
-
|
|
11
11
|
import {FetchException, HoistException, TimeoutException, TimeoutExceptionConfig} from './Types';
|
|
12
12
|
|
|
13
13
|
/**
|
|
@@ -39,15 +39,19 @@ export class Exception {
|
|
|
39
39
|
});
|
|
40
40
|
}
|
|
41
41
|
|
|
42
|
-
/**
|
|
43
|
-
* Create an Error for when an operation (e.g. a Promise) times out.
|
|
44
|
-
*/
|
|
42
|
+
/** Create an Error for when an operation (e.g. a Promise) times out. */
|
|
45
43
|
static timeout(config: TimeoutExceptionConfig): TimeoutException {
|
|
46
44
|
const {interval, ...rest} = config,
|
|
47
|
-
|
|
45
|
+
// Display timeout in seconds if an even multiple (or very close to it).
|
|
46
|
+
displayInterval =
|
|
47
|
+
interval % 1000 < 5
|
|
48
|
+
? pluralize('second', Math.round(interval / 1000), true)
|
|
49
|
+
: `${interval}ms`;
|
|
50
|
+
|
|
48
51
|
return this.createInternal({
|
|
49
52
|
name: 'Timeout Exception',
|
|
50
|
-
message
|
|
53
|
+
// Note FetchService.managedFetchAsync appends to this message - review if changing.
|
|
54
|
+
message: `Timed out after ${displayInterval}`,
|
|
51
55
|
isTimeout: true,
|
|
52
56
|
stack: null,
|
|
53
57
|
interval,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@xh/hoist",
|
|
3
|
-
"version": "70.0.0-SNAPSHOT.
|
|
3
|
+
"version": "70.0.0-SNAPSHOT.1731001551514",
|
|
4
4
|
"description": "Hoist add-on for building and deploying React Applications.",
|
|
5
5
|
"repository": "github:xh/hoist-react",
|
|
6
6
|
"homepage": "https://xh.io",
|
|
@@ -31,7 +31,7 @@
|
|
|
31
31
|
},
|
|
32
32
|
"dependencies": {
|
|
33
33
|
"@auth0/auth0-spa-js": "~2.1.3",
|
|
34
|
-
"@azure/msal-browser": "~3.
|
|
34
|
+
"@azure/msal-browser": "~3.27.0",
|
|
35
35
|
"@blueprintjs/core": "^5.10.5",
|
|
36
36
|
"@blueprintjs/datetime": "^5.3.7",
|
|
37
37
|
"@blueprintjs/datetime2": "^2.3.7",
|
|
@@ -65,7 +65,7 @@
|
|
|
65
65
|
"moment": "~2.30.1",
|
|
66
66
|
"numbro": "~2.5.0",
|
|
67
67
|
"onsenui": "~2.12.8",
|
|
68
|
-
"qs": "~6.
|
|
68
|
+
"qs": "~6.13.0",
|
|
69
69
|
"react-beautiful-dnd": "~13.1.0",
|
|
70
70
|
"react-dates": "~21.8.0",
|
|
71
71
|
"react-dropzone": "~10.2.2",
|
|
@@ -84,7 +84,7 @@
|
|
|
84
84
|
"router5-plugin-browser": "~7.0.2",
|
|
85
85
|
"semver": "~7.6.0",
|
|
86
86
|
"short-unique-id": "~5.2.0",
|
|
87
|
-
"store2": "~2.
|
|
87
|
+
"store2": "~2.14.3",
|
|
88
88
|
"ua-parser-js": "~1.0.2"
|
|
89
89
|
},
|
|
90
90
|
"peerDependencies": {
|
package/svc/FetchService.ts
CHANGED
|
@@ -314,7 +314,8 @@ export class FetchService extends HoistService {
|
|
|
314
314
|
const msg =
|
|
315
315
|
isObject(timeout) && 'message' in timeout
|
|
316
316
|
? timeout.message
|
|
317
|
-
:
|
|
317
|
+
: // Exception.timeout() message already includes interval - add URL here.
|
|
318
|
+
e.message + ` loading '${opts.url}'`;
|
|
318
319
|
throw Exception.fetchTimeout(opts, e, msg);
|
|
319
320
|
}
|
|
320
321
|
|